OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <style> | 3 <style> |
4 #inspected | 4 #inspected |
5 { | 5 { |
6 color: green; | 6 color: green; |
7 } | 7 } |
8 </style> | 8 </style> |
9 <script src="../inspector-test.js"></script> | 9 <script src="../inspector-test.js"></script> |
10 <script src="../elements-test.js"></script> | 10 <script src="../elements-test.js"></script> |
11 <script> | 11 <script> |
12 | 12 |
13 function addStylesheet() | 13 function addStylesheet() |
14 { | 14 { |
15 var linkElement = document.createElement("link"); | 15 var linkElement = document.createElement("link"); |
16 linkElement.rel = "stylesheet"; | 16 linkElement.rel = "stylesheet"; |
17 linkElement.href = "resources/selector-line-deprecated.css"; | 17 linkElement.href = "resources/selector-line-deprecated.css"; |
18 document.head.appendChild(linkElement); | 18 document.head.appendChild(linkElement); |
19 } | 19 } |
20 | 20 |
21 function test() | 21 function test() |
22 { | 22 { |
23 WebInspector.experimentsSettings.sass.isEnabled = function() { return true;
} | 23 WebInspector.experimentsSettings.sass.isEnabled = function() { return true;
} |
24 InspectorTest.addConsoleSniffer(step1); | 24 InspectorTest.evaluateInPage("addStylesheet()", step1); |
25 InspectorTest.evaluateInPage("addStylesheet()"); | |
26 | 25 |
27 function step1() | 26 function step1() |
28 { | 27 { |
29 WebInspector.showPanel("elements"); | 28 WebInspector.showPanel("elements"); |
30 InspectorTest.selectNodeAndWaitForStyles("inspected", step2); | 29 InspectorTest.selectNodeAndWaitForStyles("inspected", step2); |
31 } | 30 } |
32 | 31 |
33 function step2() | 32 function step2() |
34 { | 33 { |
35 InspectorTest.dumpSelectedElementStyles(true); | 34 InspectorTest.dumpSelectedElementStyles(true); |
36 InspectorTest.completeTest(); | 35 InspectorTest.completeTest(); |
37 } | 36 } |
38 } | 37 } |
39 | 38 |
40 </script> | 39 </script> |
41 </head> | 40 </head> |
42 | 41 |
43 <body onload="runTest()"> | 42 <body onload="runTest()"> |
44 <p> | 43 <p> |
45 Tests that selector line is computed correctly regardless of its start column. <
a href="https://bugs.webkit.org/show_bug.cgi?id=110732">Bug 110732</a>. | 44 Tests that selector line is computed correctly regardless of its start column. <
a href="https://bugs.webkit.org/show_bug.cgi?id=110732">Bug 110732</a>. |
46 </p> | 45 </p> |
47 | 46 |
48 <div id="container"> | 47 <div id="container"> |
49 <div id="inspected">Text</div> | 48 <div id="inspected">Text</div> |
50 </div> | 49 </div> |
51 | 50 |
52 </body> | 51 </body> |
53 </html> | 52 </html> |
OLD | NEW |