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

Side by Side Diff: LayoutTests/fast/backgrounds/multiple-backgrounds-initial-values.html

Issue 128203003: Teach mapFill{X,Y}Position about initial values to individual background layers (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 11 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
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script src="../../resources/js-test.js"></script>
3 <style>
4 .test {
5 background: url(resources/dot.png) no-repeat -10px 50px,
6 linear-gradient(to bottom, green 0%, lime 100%);
7 width: 100px;
8 height: 100px;
9 visibility: hidden;
10 }
11 </style>
12 <div class="test"></div>
13 <script>
14 description("Test that background position values do not leak between layers") ;
15 var e = document.querySelector('.test');
16
17 var bgPosLayers = getComputedStyle(e).backgroundPosition.split(', ');
18
19 var bgPosLayer1 = bgPosLayers[0];
20 shouldBeGreaterThanOrEqual('bgPosLayers[0].search("-10px")', '0');
21 shouldBeGreaterThanOrEqual('bgPosLayers[0].search("50px")', '0');
Julien - ping for review 2014/01/10 13:37:03 Couldn't we just use the explicit position here in
davve 2014/01/10 14:09:49 I like the ability to run (and PASS) the test in F
22
23 var bgPosLayer2 = bgPosLayers[1];
24 shouldBe('bgPosLayers[1].search("-10px")', "-1");
25 shouldBe('bgPosLayers[1].search("50px")', "-1");
26 </script>
27
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698