27 lines
1.3 KiB
HTML
27 lines
1.3 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
|
|
<html>
|
|
<head>
|
|
<script src="../../resources/js-test-pre.js"></script>
|
|
</head>
|
|
<body>
|
|
<script>
|
|
description(
|
|
'This test checks createConicGradient with infinite values'
|
|
);
|
|
|
|
var ctx = document.createElement('canvas').getContext('2d');
|
|
|
|
shouldThrow("ctx.createConicGradient(0, 100, NaN)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(0, 100, Infinity)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(0, 100, -Infinity)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(0, NaN, 100)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(0, Infinity, 100)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(0, -Infinity, 100)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(NaN, 100, 100)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(Infinity, 100, 100)", "'TypeError: The provided value is non-finite'");
|
|
shouldThrow("ctx.createConicGradient(-Infinity, 100, 100)", "'TypeError: The provided value is non-finite'");
|
|
</script>
|
|
<script src="../../resources/js-test-post.js"></script>
|
|
</body>
|
|
</html>
|