tizen beta release
[framework/web/webkit-efl.git] / LayoutTests / fast / css / stale-style-selector-crash-2.html
1 <html>
2 <head id="head">
3     <style id="inlineRules">
4         #foo { background-color: red; }
5     </style>
6     <link rel="stylesheet" href="data:text/css,">
7 </head>
8 <body>
9     <p>
10         Test for <i><a href="http://bugs.webkit.org/show_bug.cgi?id=13563">http://bugs.webkit.org/show_bug.cgi?id=13563</a>
11         REGRESSION: Crash loading message in Yahoo! Mail</i>.
12     </p>
13     <p>
14         The following line should say SUCCESS in green letters over a white background.
15     </p>
16     <div id="foo">SUCCESS</div>
17     <script>
18         if (window.layoutTestController)
19             layoutTestController.dumpAsText();
20
21         // Force a layout ignoring pending stylesheets
22         document.body.offsetTop;
23
24         var inline = document.getElementById("inlineRules");
25         // This will delete the rule (duh) but since we have
26         // pending stylesheets, will NOT update the style selector
27         inline.sheet.deleteRule(0);
28
29         // Make ourselves need a style recalc, so that
30         // updateRendering() will do something when called soon
31         document.getElementById("foo").style.color = "green";
32     </script>
33 </body>
34 </html>