OLD | NEW |
(Empty) | |
| 1 if (this.document === undefined) { |
| 2 importScripts("/resources/testharness.js"); |
| 3 importScripts("../resources/utils.js"); |
| 4 } |
| 5 |
| 6 function checkKoUrl(url, desc) { |
| 7 if (!desc) |
| 8 desc = "Fetching " + url.substring(0, 45) + " is KO" |
| 9 promise_test(function(test) { |
| 10 var promise = fetch(url); |
| 11 return promise_rejects(test, new TypeError(), promise); |
| 12 }, desc); |
| 13 } |
| 14 |
| 15 var urlWithoutScheme = "://{{host}}:{{ports[http][0]}}/"; |
| 16 checkKoUrl("aaa" + urlWithoutScheme); |
| 17 checkKoUrl("cap" + urlWithoutScheme); |
| 18 checkKoUrl("cid" + urlWithoutScheme); |
| 19 checkKoUrl("dav" + urlWithoutScheme); |
| 20 checkKoUrl("dict" + urlWithoutScheme); |
| 21 checkKoUrl("dns" + urlWithoutScheme); |
| 22 checkKoUrl("geo" + urlWithoutScheme); |
| 23 checkKoUrl("im" + urlWithoutScheme); |
| 24 checkKoUrl("imap" + urlWithoutScheme); |
| 25 checkKoUrl("ipp" + urlWithoutScheme); |
| 26 checkKoUrl("ldap" + urlWithoutScheme); |
| 27 checkKoUrl("mailto" + urlWithoutScheme); |
| 28 checkKoUrl("nfs" + urlWithoutScheme); |
| 29 checkKoUrl("pop" + urlWithoutScheme); |
| 30 checkKoUrl("rtsp" + urlWithoutScheme); |
| 31 checkKoUrl("snmp" + urlWithoutScheme); |
| 32 |
| 33 done(); |
OLD | NEW |