| OLD | NEW |
| 1 <?php | 1 <?php header("Suborigin: foobar"); ?> |
| 2 header("Suborigin: foobar"); | |
| 3 ?> | |
| 4 <!DOCTYPE html> | 2 <!DOCTYPE html> |
| 5 <html> | 3 <html> |
| 6 <head> | 4 <head> |
| 7 <title>Service worker JavaScript API fails from a suborigin</title> | 5 <title>WebSocket access is disallowed in suborigins</title> |
| 8 <script src="/resources/testharness.js"></script> | 6 <script src="/resources/testharness.js"></script> |
| 9 <script src="/resources/testharnessreport.js"></script> | 7 <script src="/resources/testharnessreport.js"></script> |
| 10 </head> | 8 </head> |
| 9 <body> |
| 11 <script> | 10 <script> |
| 12 var expectedError = new DOMException("TEST EXCEPTION", "SecurityError"); | 11 var expectedError = new DOMException("TEST EXCEPTION", "SecurityError"); |
| 13 assert_throws(expectedError, function() { | 12 assert_throws(expectedError, function() { |
| 14 navigator.serviceWorker; | 13 var ws = new WebSocket("ws://127.0.0.1:8880/simple"); |
| 15 }); | 14 }); |
| 16 done(); | 15 done(); |
| 17 </script> | 16 </script> |
| 17 </body> |
| 18 </html> | 18 </html> |
| OLD | NEW |