blob: 395ad769d614ada04b69835d7db2c00ed0b8dc5a [file] [log] [blame]
Series of tests to ensure stroke() works with optional path parameter.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Testing stroke()
PASS pixelDataAtPoint()[0] is within 5 of 0
PASS pixelDataAtPoint()[1] is within 5 of 255
PASS pixelDataAtPoint()[2] is within 5 of 0
PASS pixelDataAtPoint()[3] is within 5 of 255
Testing stroke(path)
PASS pixelDataAtPoint()[0] is within 5 of 0
PASS pixelDataAtPoint()[1] is within 5 of 255
PASS pixelDataAtPoint()[2] is within 5 of 0
PASS pixelDataAtPoint()[3] is within 5 of 255
PASS ctx.stroke(null) threw exception TypeError: Failed to execute 'stroke' on 'CanvasRenderingContext2D': parameter 1 is not of type 'Path2D'..
PASS ctx.stroke(undefined) threw exception TypeError: Failed to execute 'stroke' on 'CanvasRenderingContext2D': parameter 1 is not of type 'Path2D'..
PASS ctx.stroke([]) threw exception TypeError: Failed to execute 'stroke' on 'CanvasRenderingContext2D': parameter 1 is not of type 'Path2D'..
PASS ctx.stroke({}) threw exception TypeError: Failed to execute 'stroke' on 'CanvasRenderingContext2D': parameter 1 is not of type 'Path2D'..
PASS successfullyParsed is true
TEST COMPLETE