Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / backgrounds / background-shorthand-after-set-backgroundSize.html
blobe928294d06a5cee83a10d7094a43f75e96b76ce3
1 <!DOCTYPE html>
2 <html>
3 <script src="../../resources/js-test.js"></script>
4 <div id="test"> </div>
5 <script>
6 description("Tests a flag to make background shorthand property not override background-size when it's already set.");
8 var e = document.getElementById('test');
10 if (window.internals) {
11 window.internals.settings.setUseLegacyBackgroundSizeShorthandBehavior(true);
13 e.style.backgroundSize = "cover";
14 e.style.background = "center red url(dummy://test.png) no-repeat border-box";
15 shouldBe("e.style.background", "'url(dummy://test.png) 50% 50% / cover no-repeat border-box border-box red'")
16 shouldBe("e.style.backgroundSize", "'cover'");
17 debug("")
19 window.internals.settings.setUseLegacyBackgroundSizeShorthandBehavior(false);
22 </script>
23 </body>
24 </html>