From-Origin: Support for 'same' and 'same-site' response header, nested frame origin...
[WebKit.git] / LayoutTests / http / tests / from-origin / image-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 image load fails if the server blocks it with a 'From-Origin: same' response header.");
7         jsTestIsAsync = true;
8
9         function imageLoadError() {
10             testPassed("Image load blocked.");
11             finishJSTest();
12         }
13
14         function imageLoadSuccess() {
15             testFailed("Image load succeeded.");
16             finishJSTest();
17         }
18     </script>
19 </head>
20 <body>
21 <img src="http://localhost:8000/from-origin/resources/image.php?fromOrigin=same" onerror="imageLoadError()" onload="imageLoadSuccess()">
22 </body>
23 </html>