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

Side by Side Diff: LayoutTests/fast/repaint/background-shorthand-with-gradient-and-height-changes.html

Issue 263553005: Convert repaintRectsAsText callers to text-based-repaint.js (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase again Created 6 years, 7 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 <html> 1 <html>
2 <head> 2 <head>
3 <script>jsTestIsAsync = true;</script> 3 <script src="resources/text-based-repaint.js"></script>
4 <script src="../../resources/js-test.js"></script>
5 4
6 <style> 5 <style>
7 #outer { 6 #outer {
8 padding-top: 200px; 7 padding-top: 200px;
9 /* background-size is implicitly set to initial via the background shorthand . */ 8 /* background-size is implicitly set to initial via the background shorthand . */
10 background:-webkit-gradient( 9 background:-webkit-gradient(
11 linear, 10 linear,
12 left top, 11 left top,
13 left bottom, 12 left bottom,
14 color-stop(0%, rgba(255,255,0,0)), color-stop(100%, rgba(0,0,0,1)) 13 color-stop(0%, rgba(255,255,0,0)), color-stop(100%, rgba(0,0,0,1))
15 ); 14 );
16 } 15 }
17 16
18 #inner { 17 #inner {
19 height: 100px; 18 height: 100px;
20 } 19 }
21 </style> 20 </style>
22 21
23 <script> 22 <script>
24 description("This test verifies that gradient background gets repainted properly after child box height change."); 23 //This test verifies that gradient background gets repainted properly after chil d box height change.
25 24
26 function start() { 25 function repaintTest() {
27 window.setTimeout(function() { 26 document.getElementById('inner').style.height = 300 + 'px';
28 document.getElementById('inner').style.height = 300 + 'px';
29 window.setTimeout(logRepaints, 200);
30 }, 0);
31
32 if (!window.testRunner || !window.internals)
33 return;
34
35 window.internals.startTrackingRepaints(document);
36 var dummy = document.body.offsetTop;
37 }
38
39 function logRepaints() {
40 if (!window.internals)
41 return;
42
43 repaintRects = window.internals.repaintRectsAsText(document);
44 window.internals.stopTrackingRepaints(document);
45 shouldNotBe("repaintRects.indexOf('500')", "-1");
46 finishJSTest();
47 } 27 }
48 </script> 28 </script>
49 </head> 29 </head>
50 30 <body onload='runRepaintTest();'>
51 <body onload='start();'>
52 <div id='outer'> 31 <div id='outer'>
53 <div id='inner'> 32 <div id='inner'>
54 </div> 33 </div>
55 </div> 34 </div>
56 </body> 35 </body>
57 </html> 36 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698