[chromium] Unreviewed. Rebaseline layout tests.
[WebKit-https.git] / LayoutTests / inspector / styles-source-lines-inline.html
1 <html>
2 <head>
3 <script src="../http/tests/inspector/inspector-test.js"></script>
4 <script src="elements-tests.js"></script>
5
6 <style>
7 .foo {
8     color: blue;
9 }
10 </style>
11
12 <script>
13
14 function doit()
15 {
16     runAfterIframeIsLoaded(function() {
17         function callback(result)
18         {
19             dumpArray(result);
20             notifyDone();
21         }
22         evaluateInWebInspector("frontend_dumpStyles", callback);
23     });
24 }
25
26 // Frontend functions.
27
28 function frontend_dumpStyles(testController)
29 {
30     testController.waitUntilDone();
31     frontend_expandDOMSubtreeAndRun(testController, null, frontend_selectElementContinuation);
32 }
33
34 function frontend_selectElementContinuation(testController)
35 {
36     frontend_selectElementAndRun(testController, "foo", frontend_selectElementContinuation2);
37 }
38
39 function frontend_selectElementContinuation2(testController)
40 {
41     var result = frontend_getSelectedElementStyles(true);
42     function dumpSelectedElementStyles()
43     {
44         result = result.concat(frontend_getSelectedElementStyles(true));
45         testController.notifyDone(result);
46     }
47     frontend_selectElementAndRun(testController, "bar", dumpSelectedElementStyles);
48 }
49
50 </script>
51 </head>
52
53 <body onload="onload()">
54 <p>
55 Tests that elements panel shows proper inline style locations in the sidebar panel.
56 </p>
57
58 <div id="foo" class="foo" style="display:none">Foo</div>
59 <iframe src="resources/styles-source-lines-inline-iframe.html">
60
61 </body>
62 </html>