Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(142)

Side by Side Diff: LayoutTests/fast/canvas/canvas-resize-after-paint-without-layout.html

Issue 24438004: Rename testRunner.dumpAsText(true) to testRunner.dumpAsTextWithPixelResults() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: more tests Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <!-- Check that resizing a (potentially accelerated) canvas properly clears its 2 <!-- Check that resizing a (potentially accelerated) canvas properly clears its
3 contents even if the layout size of the canvas does not change. Expected 3 contents even if the layout size of the canvas does not change. Expected
4 output is a blank canvas. 4 output is a blank canvas.
5 https://bugs.webkit.org/show_bug.cgi?id=80871 --> 5 https://bugs.webkit.org/show_bug.cgi?id=80871 -->
6 <html> 6 <html>
7 <head> 7 <head>
8 <style> 8 <style>
9 #canvas { 9 #canvas {
10 outline: solid 1px black; 10 outline: solid 1px black;
11 width: 300px; 11 width: 300px;
12 height: 300px; 12 height: 300px;
13 } 13 }
14 </style> 14 </style>
15 <script src="resources/repaint.js"></script> 15 <script src="resources/repaint.js"></script>
16 <script> 16 <script>
17 if (window.testRunner) 17 if (window.testRunner)
18 testRunner.dumpAsText(true); 18 testRunner.dumpAsTextWithPixelResults();
19 19
20 function runTest() { 20 function runTest() {
21 var canvas = document.getElementById('canvas'); 21 var canvas = document.getElementById('canvas');
22 var ctx = canvas.getContext('2d'); 22 var ctx = canvas.getContext('2d');
23 ctx.fillStyle = 'red'; 23 ctx.fillStyle = 'red';
24 ctx.fillRect(0, 0, 300, 300); 24 ctx.fillRect(0, 0, 300, 300);
25 runRepaintTest(); 25 runRepaintTest();
26 } 26 }
27 27
28 function repaintTest() { 28 function repaintTest() {
29 var canvas = document.getElementById('canvas'); 29 var canvas = document.getElementById('canvas');
30 // This changes the resolution of the canvas but keeps its layout size c onstant. 30 // This changes the resolution of the canvas but keeps its layout size c onstant.
31 canvas.width = canvas.width / 2; 31 canvas.width = canvas.width / 2;
32 } 32 }
33 </script> 33 </script>
34 </head> 34 </head>
35 <body onload="runTest();"> 35 <body onload="runTest();">
36 <canvas id="canvas" width="300" height="300"/> 36 <canvas id="canvas" width="300" height="300"/>
37 </body> 37 </body>
38 </html> 38 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/canvas/canvas-incremental-repaint-2.html ('k') | LayoutTests/fast/canvas/canvas-resize-reset.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698