Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / css / pseudo-required-optional-005.html
blob495e408e496bffb6ddbaa227e7654808330772bb
1 <html>
2 <head>
3 <title>required/optional CSS pseudoclasses part 5</title>
4 <script src="../../resources/js-test.js"></script>
5 <style>
6 input:optional { background: lime; }
7 input { background: red; }
8 input:required { background: red; }
9 </style>
10 </head>
11 <body>
12 <input id="range" type="range" required/>
13 <input id="submit" type="submit" required/>
14 <input id="image" type="image" required/>
15 <input id="reset" type="reset" required/>
16 <input id="button" type="button" required/>
17 <script language="JavaScript" type="text/javascript">
18 function isOptional(id) {
19 return document.defaultView.getComputedStyle(document.getElementById(id), null).getPropertyValue('background-color') == "rgb(0, 255, 0)"
21 description('This test checks the CSS pseudoclasses for input types.');
22 shouldBeTrue('isOptional("range")');
23 shouldBeTrue('isOptional("submit")');
24 shouldBeTrue('isOptional("image")');
25 shouldBeTrue('isOptional("reset")');
26 shouldBeTrue('isOptional("button")');
27 </script>
28 </body>
29 </html>