Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/fast/canvas/canvas-invalid-fillstyle.html |
| diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-invalid-fillstyle.html b/third_party/WebKit/LayoutTests/fast/canvas/canvas-invalid-fillstyle.html |
| index 2939430bb418437f356ed31f0b4ddce17e1e92f2..48828c6036dfa5ad693792cf84ba526da490d7a0 100644 |
| --- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-invalid-fillstyle.html |
| +++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-invalid-fillstyle.html |
| @@ -1,10 +1,18 @@ |
| -<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
| -<html> |
| -<head> |
| -<script src="../../resources/js-test.js"></script> |
| -</head> |
| +<script src="../../resources/testharness.js"></script> |
| +<script src="../../resources/testharnessreport.js"></script> |
| <body> |
| <canvas id="canvas" width="200" height="200"></canvas> |
| -<script src="canvas-invalid-fillstyle.js"></script> |
| +<script> |
| +test(function(t) { |
| + var ctx = document.getElementById('canvas').getContext('2d'); |
| + ctx.fillStyle = 'rgb(0, 255, 0)'; |
| + ctx.fillStyle = 'nonsense'; |
| + ctx.fillRect(0, 0, 200, 200); |
| + var imageData = ctx.getImageData(0, 0, 200, 200); |
| + var imgdata = imageData.data; |
| + assert_equals(imgdata[4], 0); |
| + assert_equals(imgdata[5], 255); |
| + assert_equals(imgdata[6], 0); |
| +}, 'Series of tests to ensure correct behaviour on an invalid fillStyle()'); |
|
Justin Novosad
2017/02/16 15:34:29
This is not really a series
zakerinasab
2017/02/16 17:48:12
Acknowledged.
|
| +</script> |
| </body> |
| -</html> |