Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / css / attribute-selector-recursive-update-on-setAttribute.html
blobd5ef0bfc182e8e1978a12e25a97b344c0cd8f90e
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <meta charset="utf-8">
5 <script src="../../resources/js-test.js"></script>
6 <style>
7 .entry[status="foo"] .toggle {
8 color: green;
10 .entry[status="bar"] .toggle {
11 color: red;
13 </style>
14 </head>
15 <body>
16 <div class="entry" status="foo">
17 <span class="toggle">Text.</span>
18 </div>
19 <script>
21 description("This test checks that attribute selectors are recursively re-evaluated when the attribute changes.");
23 var entry= document.getElementsByClassName("entry")[0];
24 var toggle = document.getElementsByClassName("toggle")[0];
26 shouldBe("getComputedStyle(toggle).color", "'rgb(0, 128, 0)'");
27 entry.setAttribute("status", "bar");
28 shouldBe("getComputedStyle(toggle).color", "'rgb(255, 0, 0)'");
30 document.body.removeChild(entry);
32 </script>
33 </body>
34 </html>