OLD | NEW |
(Empty) | |
| 1 <html> |
| 2 <head> |
| 3 <script src="../../../http/tests/inspector/inspector-test.js"></script> |
| 4 <script src="../../../http/tests/inspector/elements-test.js"></script> |
| 5 <script> |
| 6 |
| 7 function embedInlineStyleSheet() |
| 8 { |
| 9 var style = document.createElement("style"); |
| 10 style.type = "text/css"; |
| 11 style.textContent = document.querySelector(".stylesheet-text").textContent; |
| 12 document.head.appendChild(style); |
| 13 } |
| 14 |
| 15 function test() |
| 16 { |
| 17 WebInspector.targetManager.addModelListener(WebInspector.CSSModel, WebInspec
tor.CSSModel.Events.StyleSheetAdded, onStyleSheetAdded); |
| 18 InspectorTest.evaluateInPage("embedInlineStyleSheet()", function() { }); |
| 19 |
| 20 function onStyleSheetAdded(event) |
| 21 { |
| 22 var header = event.data; |
| 23 |
| 24 InspectorTest.addResult("\nheader.sourceMapURL = " + header.sourceMapURL
); |
| 25 InspectorTest.completeTest(); |
| 26 } |
| 27 }; |
| 28 |
| 29 </script> |
| 30 |
| 31 </head> |
| 32 |
| 33 <body onload="runTest()"> |
| 34 <p>Verify that inline style sourceMappingURL is resolved properly.</p> |
| 35 <pre class="stylesheet-text">.red,body{color:red}body{background-color:red} |
| 36 /*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIj
pbIm1peGluLmxlc3MiLCJ0ZXN0Lmxlc3MiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsS0NJQS
xLREhFLE1BQUEsSUNHRixLQUVFLGlCQUFBIn0=*/</pre> |
| 37 |
| 38 </body> |
| 39 </html> |
OLD | NEW |