1 /* verify that certain invalid URIs are not parsed by the resource
4 const Cc = Components.classes;
5 const Ci = Components.interfaces;
6 const Cr = Components.results;
10 "resource:///http://www.mozilla.org/",
11 "resource:///file:///",
13 "resource:///..\\..\\",
18 function check_for_exception(spec)
21 Cc["@mozilla.org/network/io-service;1"].
22 getService(Ci.nsIIOService);
25 var channel = ios.newChannel(spec, null, null);
31 do_throw("Succesfully opened invalid URI: '" + spec + "'");
35 for each (spec in specs) {
36 check_for_exception(spec);