2d.imageData.create2.zero

createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero

Actual output:

FAIL (fallback content)

Summary

Harness status: OK

Found 1 tests

Details

ResultTest NameMessage
PasscreateImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero
Asserts run
Pass
assert_throws_dom("INDEX_SIZE_ERR", function "function() { ctx.createImageData(10, 0); }")
    at  /html/canvas/element/pixel-manipulation/2d.imageData.create2.zero.html:23:3
Pass
assert_throws_dom("INDEX_SIZE_ERR", function "function() { ctx.createImageData(0, 10); }")
    at  /html/canvas/element/pixel-manipulation/2d.imageData.create2.zero.html:24:3
Pass
assert_throws_dom("INDEX_SIZE_ERR", function "function() { ctx.createImageData(0, 0); }")
    at  /html/canvas/element/pixel-manipulation/2d.imageData.create2.zero.html:25:3
Pass
assert_throws_dom("INDEX_SIZE_ERR", function "function() { ctx.createImageData(0.99, 10); }")
    at  /html/canvas/element/pixel-manipulation/2d.imageData.create2.zero.html:26:3
Pass
assert_throws_dom("INDEX_SIZE_ERR", function "function() { ctx.createImageData(10, 0.1); }")
    at  /html/canvas/element/pixel-manipulation/2d.imageData.create2.zero.html:27:3