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

Unified Diff: LayoutTests/fast/workers/worker-constructor.html

Issue 84423002: Correctly resolve empty script URLs in Worker constructors. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 1 month 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 | LayoutTests/fast/workers/worker-constructor-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/workers/worker-constructor.html
diff --git a/LayoutTests/fast/workers/worker-constructor.html b/LayoutTests/fast/workers/worker-constructor.html
index 01f7d968d241cc9a49731ce575cfed5d5d9caa5e..38f5423ada7e4a79a6fe1f080df1c0a34905139e 100644
--- a/LayoutTests/fast/workers/worker-constructor.html
+++ b/LayoutTests/fast/workers/worker-constructor.html
@@ -71,12 +71,13 @@ function testEmptyScriptUrl()
{
try {
var worker = new Worker("");
- worker.onerror = function() {
- log("FAIL: onerror invoked for an empty script URL.");
+ worker.onerror = function(e) {
+ log("PASS: onerror invoked for an empty script URL, resolving to this HTML document's URL.");
+ e.preventDefault();
runNextTest();
}
} catch (ex) {
- log("PASS: invoking Worker constructor with empty script URL resulted in an exception (" + ex + ")");
+ log("FAIL: invoking Worker constructor with empty script URL resulted in a exception (" + ex + ")");
runNextTest();
}
}
« no previous file with comments | « no previous file | LayoutTests/fast/workers/worker-constructor-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698