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

Unified Diff: LayoutTests/http/tests/security/xssAuditor/resources/utilities.js

Issue 205523003: Remove beforeload events. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove more tests Created 6 years, 9 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/http/tests/security/xssAuditor/resources/utilities.js
diff --git a/LayoutTests/http/tests/security/xssAuditor/resources/utilities.js b/LayoutTests/http/tests/security/xssAuditor/resources/utilities.js
index 6075a08f4da326fb9f716fbbcee6b349b62d425c..34ec6b8f97b033b977c8768bcddadf06b20a1c39 100644
--- a/LayoutTests/http/tests/security/xssAuditor/resources/utilities.js
+++ b/LayoutTests/http/tests/security/xssAuditor/resources/utilities.js
@@ -48,16 +48,10 @@ function sendRequestFromIFrame(url, params, HTTPMethod, callbackWhenDone)
}
-function notifyDoneAfterReceivingBeforeloadFromIds(ids)
+function notifyDoneAfterReceivingLoaded()
{
- var loadAttempted = 0;
window.addEventListener("message", function(event) {
- var index = ids.indexOf(event.data);
- if (index == -1)
- return;
-
- loadAttempted = loadAttempted | (1 << index);
- if (loadAttempted == (1 << ids.length) - 1)
+ if (event.data == "loaded")
testRunner.notifyDone();
}, false);
}

Powered by Google App Engine
This is Rietveld 408576698