Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / css3 / device-adapt / viewport-invalid-values-001.html
blob7753560057d96678f3d07059ddd94506510ea86d
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <title>'initial' and 'inherit' are invalid values for @viewport descriptors</title>
5 <script src="../../resources/testharness.js"></script>
6 <script src="../../resources/testharnessreport.js"></script>
7 <script>
8 if (window.testRunner) {
9 internals.settings.setViewportEnabled(true);
11 </script>
12 <style>
13 /* 'initial' and 'inherit' are invalid keywords for viewport descriptors. */
14 @viewport { min-width: initial; }
15 @viewport { min-width: inherit; }
16 </style>
17 </head>
18 <body>
19 <div id="log"></div>
20 <script>
21 test(function(){
22 assert_equals(document.styleSheets[0].cssRules.length, 2);
23 }, "Check that both @viewport rules are created.");
24 test(function(){
25 assert_equals(document.styleSheets[0].cssRules[0].style.length, 0);
26 }, "Check that \"min-width: initial\" is dropped.");
27 test(function(){
28 assert_equals(document.styleSheets[0].cssRules[0].style.length, 0);
29 }, "Check that \"min-width: inherit\" is dropped.");
30 </script>
31 </body>
32 </html>