OLD | NEW |
---|---|
1 <!DOCTYPE html> | 1 importScripts('../../../resources/js-test.js'); |
Justin Novosad
2016/01/06 15:29:40
Factoring-out the js into a separate file is old-s
| |
2 <script src="../../resources/js-test.js"></script> | 2 |
3 <script> | 3 description("Tests that the OffScreenCanvas can be constructed on a worker threa d."); |
4 description("Tests that the constructor of the OffScreenCanvas can be called on the main thread"); | |
5 | 4 |
6 var aCanvas = new OffScreenCanvas(50, 50); | 5 var aCanvas = new OffScreenCanvas(50, 50); |
7 shouldBe("aCanvas.width", "50"); | 6 shouldBe("aCanvas.width", "50"); |
8 shouldBe("aCanvas.height", "50"); | 7 shouldBe("aCanvas.height", "50"); |
9 | 8 |
10 aCanvas.width = 100; | 9 aCanvas.width = 100; |
11 aCanvas.height = 100; | 10 aCanvas.height = 100; |
12 shouldBe("aCanvas.width", "100"); | 11 shouldBe("aCanvas.width", "100"); |
13 shouldBe("aCanvas.height", "100"); | 12 shouldBe("aCanvas.height", "100"); |
14 </script> | 13 |
14 finishJSTest(); | |
OLD | NEW |