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

Side by Side Diff: LayoutTests/http/tests/security/script-crossorigin-onerror-information.html

Issue 19596004: Allow sites to enable 'window.onerror' handlers for cross-domain scripts. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase. Created 7 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <head>
3 </head>
4 <body>
5 <script src="../../js-test-resources/js-test-pre.js"></script>
6 <script>
7 window.jsTestIsAsync = true;
8 description("The test passes if window.onerror gets unsanitized information abou t the script error.");
9
10 window.onerror = function(msg, url, line) {
11 window.msg = msg;
12 window.url = url;
13 window.line = line;
14 shouldBeEqualToString("msg.match(/SomeError/)[0]", "SomeError");
15 shouldBeEqualToString("url", "http://localhost:8000/security/resources/cors- script.php?fail=true");
16 shouldBe("line", "1");
17 finishJSTest();
18 }
19 </script>
20 <script crossorigin=" anonymous " src="http://localhost:8000/security/resourc es/cors-script.php?fail=true"></script>
21 <script src="../../js-test-resources/js-test-post.js"></script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698