blob: 5770a7a3af03d7652e1418ca6c2c8b74465b8465 [file] [log] [blame]
This test covers the behaviour of pattern use and construction
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS context.createPattern(green1x1, null) did not throw an exception
PASS getPixel(1,1) is [0,128,0,255]
PASS getPixel(98,1) is [0,128,0,255]
PASS getPixel(1,48) is [0,128,0,255]
PASS getPixel(98,48) is [0,128,0,255]
PASS context.createPattern(green1x1, 'null') threw exception SyntaxError: An invalid or illegal string was specified..
PASS context.createPattern(green1x1, undefined) threw exception SyntaxError: An invalid or illegal string was specified..
PASS context.createPattern(green1x1, 'undefined') threw exception SyntaxError: An invalid or illegal string was specified..
PASS context.createPattern(green1x1, {toString:function(){ return null;}}) threw exception SyntaxError: An invalid or illegal string was specified..
PASS context.createPattern(green1x1, '') did not throw an exception
PASS getPixel(1,1) is [0,128,0,255]
PASS getPixel(98,1) is [0,128,0,255]
PASS getPixel(1,48) is [0,128,0,255]
PASS getPixel(98,48) is [0,128,0,255]
PASS context.createPattern(green1x1, {toString:function(){ return 'repeat';}}) did not throw an exception
PASS getPixel(1,1) is [0,128,0,255]
PASS getPixel(98,1) is [0,128,0,255]
PASS getPixel(1,48) is [0,128,0,255]
PASS getPixel(98,48) is [0,128,0,255]
PASS getPixel(1,1) is [0,128,0,255]
PASS getPixel(98,1) is [0,128,0,255]
PASS getPixel(1,48) is [0,128,0,255]
PASS getPixel(98,48) is [0,128,0,255]
PASS successfullyParsed is true
TEST COMPLETE