| OLD | NEW |
| 1 description("Series of tests to ensure fill() works with path and winding rule p
arameters."); | 1 description("Series of tests to ensure fill() works with path and winding rule p
arameters."); |
| 2 | 2 |
| 3 var ctx = document.getElementById('canvas').getContext('2d'); | 3 var ctx = document.getElementById('canvas').getContext('2d'); |
| 4 | 4 |
| 5 function pixelDataAtPoint() { | 5 function pixelDataAtPoint() { |
| 6 return ctx.getImageData(50, 50, 1, 1).data; | 6 return ctx.getImageData(50, 50, 1, 1).data; |
| 7 } | 7 } |
| 8 | 8 |
| 9 function checkResult(expectedColors, sigma) { | 9 function checkResult(expectedColors, sigma) { |
| 10 for (var i = 0; i < 4; i++) | 10 for (var i = 0; i < 4; i++) |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 shouldThrow("ctx.fill(null, null)"); | 66 shouldThrow("ctx.fill(null, null)"); |
| 67 shouldThrow("ctx.fill(null, 'nonzero')"); | 67 shouldThrow("ctx.fill(null, 'nonzero')"); |
| 68 shouldThrow("ctx.fill(path, null)"); | 68 shouldThrow("ctx.fill(path, null)"); |
| 69 shouldThrow("ctx.fill([], 'nonzero')"); | 69 shouldThrow("ctx.fill([], 'nonzero')"); |
| 70 shouldThrow("ctx.fill({}, 'nonzero')"); | 70 shouldThrow("ctx.fill({}, 'nonzero')"); |
| 71 shouldThrow("ctx.fill(null, 'evenodd')"); | 71 shouldThrow("ctx.fill(null, 'evenodd')"); |
| 72 shouldThrow("ctx.fill([], 'evenodd')"); | 72 shouldThrow("ctx.fill([], 'evenodd')"); |
| 73 shouldThrow("ctx.fill({}, 'evenodd')"); | 73 shouldThrow("ctx.fill({}, 'evenodd')"); |
| 74 shouldThrow("ctx.fill('gazonk')"); | 74 shouldThrow("ctx.fill('gazonk')"); |
| 75 shouldThrow("ctx.fill(path, 'gazonk')"); | 75 shouldThrow("ctx.fill(path, 'gazonk')"); |
| 76 shouldThrow("ctx.fill(undefined)"); | |
| 77 shouldThrow("ctx.fill(undefined, undefined)"); | 76 shouldThrow("ctx.fill(undefined, undefined)"); |
| 78 shouldThrow("ctx.fill(undefined, path)"); | 77 shouldThrow("ctx.fill(undefined, path)"); |
| 79 shouldThrow("ctx.fill(path, undefined)"); | |
| 80 } | 78 } |
| 81 | 79 |
| 82 // Run test and allow variation of results. | 80 // Run test and allow variation of results. |
| 83 prepareTestScenario(); | 81 prepareTestScenario(); |
| OLD | NEW |