OLD | NEW |
(Empty) | |
| 1 <script src=/resources/testharness.js></script> |
| 2 <script src=/resources/testharnessreport.js></script> |
| 3 <div id=log></div> |
| 4 <script> |
| 5 var fails = ["first", "uppercase"], |
| 6 passes = ["last", "quoted", "quoted-single", "no-x"] |
| 7 |
| 8 fails.forEach(function(urlpart) { |
| 9 async_test(function(t) { |
| 10 var script = document.createElement("script") |
| 11 script.onerror = t.step_func_done(function(){}) |
| 12 script.onload = t.unreached_func("Unexpected load event") |
| 13 script.src = "resources/nosniff-" + urlpart + ".asis" |
| 14 document.body.appendChild(script) |
| 15 }, "URL query: " + urlpart) |
| 16 }) |
| 17 |
| 18 passes.forEach(function(urlpart) { |
| 19 async_test(function(t) { |
| 20 var script = document.createElement("script") |
| 21 script.onerror = t.unreached_func("Unexpected error event") |
| 22 script.onload = t.step_func_done(function(){}) |
| 23 script.src = "resources/nosniff-" + urlpart + ".asis" |
| 24 document.body.appendChild(script) |
| 25 }, "URL query: " + urlpart) |
| 26 }) |
| 27 |
| 28 </script> |
OLD | NEW |