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

Unified Diff: LayoutTests/fast/workers/worker-nested-importScripts-error.html

Issue 404513002: Propagate nested importScripts() error events outwards. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Use STACK_ALLOCATED() Created 6 years, 5 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
Index: LayoutTests/fast/workers/worker-nested-importScripts-error.html
diff --git a/LayoutTests/fast/workers/worker-nested-importScripts-error.html b/LayoutTests/fast/workers/worker-nested-importScripts-error.html
new file mode 100644
index 0000000000000000000000000000000000000000..49cdacc4ca674dad11e1e755b0567e09eca97d94
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-nested-importScripts-error.html
@@ -0,0 +1,22 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src="../../resources/js-test.js"></script>
+</head>
+<body>
+<script>
+description("This tests that errors from nested importScripts have the expected provenance.");
+
+self.jsTestIsAsync = true;
+
+var worker = startWorker("resources/importScripts-1.js");
+var event;
+worker.onerror = function (e) {
+ event = e;
+ shouldBeEqualToString("event.type", "error");
+ shouldBeTrue("event.filename.indexOf('invalidScript.js') >= 0");
+ finishJSTest();
+};
+</script>
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698