Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1538)

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading.html

Issue 2875533002: DevTools: inline SourceMaps should report data url as their url. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading.html b/third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading.html
new file mode 100644
index 0000000000000000000000000000000000000000..e2ad9473aba6262bb4fe1a0f045d682116ed4921
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading.html
@@ -0,0 +1,36 @@
+<html>
+<head>
+<script src="inspector-test.js"></script>
+
+<script>
+
+function test() {
+ var client = {};
+ var sourceMap = {
+ "file":"compiled.js",
+ "mappings":"AAASA,QAAAA,IAAG,CAACC,CAAD,CAAaC,CAAb,CACZ,CACI,MAAOD,EAAP,CAAoBC,CADxB,CAIA,IAAIC,OAAS;",
+ "sources":["source.js"],
+ "sourcesContent":["<source content>"]
+ };
+ var sourceMapURL = "data:application/json;base64," + btoa(JSON.stringify(sourceMap));
+ var scriptSource = "\n//# sourceMappingURL=" + sourceMapURL + "\n";
+ InspectorTest.evaluateInPage(scriptSource);
+ InspectorTest.debuggerModel.sourceMapManager().addEventListener(SDK.SourceMapManager.Events.SourceMapAttached, onSourceMap);
+
+ function onSourceMap(event) {
+ var sourceMap = event.data.sourceMap;
+ InspectorTest.addResult('SourceMap Loaded:');
+ InspectorTest.addResult('url: ' + sourceMap.url());
+ InspectorTest.addResult('compiledURL: ' + sourceMap.compiledURL());
+ InspectorTest.completeTest();
+ }
+}
+
+</script>
+
+</head>
+
+<body onload="runTest()">
+<p>Verify that inline sourcemap has proper URL and compiledURL.</p>
+</body>
+</html>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/inline-source-map-loading-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698