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

Side by Side Diff: third_party/WebKit/LayoutTests/external/wpt/html/semantics/scripting-1/the-script-element/module/crossorigin.html

Issue 2695813009: Import wpt@503f5b5f78ec4e87d144f78609f363f0ed0ea8db (Closed)
Patch Set: Skip some tests Created 3 years, 10 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
OLDNEW
(Empty)
1 <!doctype html>
2 <html>
3 <head>
4 <title>html-script-module-crossOrigin</title>
5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script>
7 </head>
8 <body>
9 <h1>html-script-module-crossOrigin</h1>
10 <iframe id="root-NoCORS" src="crossorigin-root-different.sub.html"></iframe>
11 <iframe id="root-WithCORS" src="crossorigin-root-same.sub.html"></iframe>
12 <iframe id="root-BlockedMissingHeader" src="crossorigin-root-missingheader.s ub.html"></iframe>
13 <iframe id="root-BlockedWrongHeader" src="crossorigin-root-wrongheader.sub.h tml"></iframe>
14 <iframe id="import-NoCORS" src="crossorigin-import-different.sub.html"></ifr ame>
15 <iframe id="import-WithCORS" src="crossorigin-import-same.sub.html"></iframe >
16 <iframe id="import-BlockedMissingHeader" src="crossorigin-import-missinghead er.sub.html"></iframe>
17 <iframe id="import-BlockedWrongHeader" src="crossorigin-import-wrongheader.s ub.html"></iframe>
18 <script>
19
20 var tests = [
21 { "obj": async_test("Root module, Error in CORS-different-origin script"), "id": "root-NoCORS", "expected": "running,0-0" },
22 { "obj": async_test("Root module, Error in CORS-same-origin scri pt"), "id": "root-WithCORS", "expected": "running,8-1" },
23 { "obj": async_test("Root module, Blocked script download, missi ng CORS ACAO header"), "id": "root-BlockedMissingHeader", "expected": "error" },
24 { "obj": async_test("Root module, Blocked script download, misma tched CORS ACAO header"), "id": "root-BlockedWrongHeader", "expected": "error" } ,
25 { "obj": async_test("Imported module, Error in CORS-different-or igin script"), "id": "import-NoCORS", "expected": "running,0-0" },
26 { "obj": async_test("Imported module, Error in CORS-same-origin script"), "id": "import-WithCORS", "expected": "running,8-1" },
27 { "obj": async_test("Imported module, Blocked script download, m issing CORS ACAO header"), "id": "import-BlockedMissingHeader", "expected": "err or" },
28 { "obj": async_test("Imported module, Blocked script download, m ismatched CORS ACAO header"), "id": "import-BlockedWrongHeader", "expected": "er ror" },
29 ];
30
31 window.addEventListener("load", function () {
32 tests.forEach(function (test) {
33 var target = document.getElementById(test.id);
34 test.obj.step(function () {
35 assert_equals(target.contentDocument._log, test.expected, "U nexpected _log value");
36 });
37 test.obj.done();
38 });
39 });
40
41 </script>
42 </body>
43 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698