From-Origin: Support for 'same' and 'same-site' response header, nested frame origin...
[WebKit.git] / LayoutTests / http / tests / from-origin / script-from-origin-same-blocked.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4     <script src="/js-test-resources/js-test.js"></script>
5     <script>
6         description("Tests that a cross-origin script load fails if the server blocks it with a 'From-Origin: same' response header.");
7         jsTestIsAsync = true;
8
9         function scriptLoadError() {
10             testPassed("Script load blocked");
11             finishJSTest();
12         }
13
14         function scriptLoadSuccess() {
15             testFailed("Script load succeeded.");
16             finishJSTest();
17         }
18     </script>
19 </head>
20 <body>
21 <script src="http://localhost:8000/from-origin/resources/script.php?fromOrigin=same" onload="scriptLoadSuccess()" onerror="scriptLoadError()"></script>
22 </body>
23 </html>