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

Side by Side Diff: LayoutTests/paint/invalidation/spv2/absolute-layer-specified-left-or-right-auto-width-moved-vertically.html

Issue 1302183007: Convert some text-based-repaint tests for spv2 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 <!-- Based on fast/repaint/absolute-layer-specified-left-or-right-auto-width-mov ed-vertically.html -->
1 <!DOCTYPE html> 2 <!DOCTYPE html>
3 <script src="resources/paint-invalidation-test.js"></script>
2 <script> 4 <script>
3 function test() 5 window.expectedPaintInvalidationObjects = [
6 ];
7 function paintInvalidationTest()
4 { 8 {
5 if (!window.testRunner || !window.internals)
6 return;
7
8 testRunner.dumpAsText();
9 document.body.offsetTop;
10 internals.startTrackingRepaints(document);
11
12 document.getElementById('left').style.top = '400px'; 9 document.getElementById('left').style.top = '400px';
13 document.getElementById('right').style.top = '400px'; 10 document.getElementById('right').style.top = '400px';
14
15 document.body.offsetTop;
16 var layerTree = internals.layerTreeAsText(document, internals.LAYER_TREE_INC LUDES_REPAINT_RECTS);
17 window.internals.stopTrackingRepaints(document);
18 document.getElementById('result').textContent = layerTree.indexOf('repaint') == -1 ? 'SUCCESS' : 'FAIL';
19 } 11 }
20 12
21 window.onload = test; 13 window.onload = runPaintInvalidationTest;
22 </script> 14 </script>
23 15
24 <style> 16 <style>
25 #left, #right { 17 #left, #right {
26 position: absolute; 18 position: absolute;
27 top: 200px; 19 top: 200px;
28 -webkit-backface-visibility: hidden; 20 -webkit-backface-visibility: hidden;
29 } 21 }
30 #left { 22 #left {
31 left: 0px; 23 left: 0px;
32 } 24 }
33 #right { 25 #right {
34 right: 0px; 26 right: 0px;
35 } 27 }
36 </style> 28 </style>
37 29
38 There should be no repaint when the divs are moved vertically. 30 There should be no repaint when the divs are moved vertically.
39 <div id="left">Left</div> 31 <div id="left">Left</div>
40 <div id="right">Right</div> 32 <div id="right">Right</div>
41 <pre id="result"></pre> 33 <pre id="result"></pre>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698