Upstream version 7.36.149.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / http / tests / inspector / elements / styles / selector-line-sourcemap-header-deprecated.html
1 <html>
2 <head>
3 <script src="../../inspector-test.js"></script>
4 <script src="../../elements-test.js"></script>
5 <script>
6
7 function addStylesheet()
8 {
9     var linkElement = document.createElement("link");
10     linkElement.rel = "stylesheet";
11     linkElement.href = "resources/selector-line-sourcemap-header-deprecated.php";
12     document.head.appendChild(linkElement);
13 }
14
15 function test()
16 {
17     WebInspector.settings.cssSourceMapsEnabled.get = function() { return true; }
18     InspectorTest.addSniffer(WebInspector.SASSSourceMapping.prototype, "_bindUISourceCode", step1);
19     InspectorTest.evaluateInPage("addStylesheet()");
20
21     function step1()
22     {
23         WebInspector.inspectorView.showPanel("elements");
24         InspectorTest.selectNodeAndWaitForStyles("inspected", step2);
25     }
26
27     function step2()
28     {
29         InspectorTest.dumpSelectedElementStyles(true);
30         InspectorTest.completeTest();
31     }
32 }
33
34 </script>
35 </head>
36
37 <body onload="runTest()">
38 <p>
39 Tests that sourcemap is applied correctly when specified by the respective HTTP header.
40 </p>
41
42 <div id="container">
43     <div id="inspected">Text</div>
44 </div>
45
46 </body>
47 </html>