4 var feedFeedURI =
ios.newURI(
"feed://example.com/feed.xml",
null,
null);
5 var httpFeedURI =
ios.newURI(
"feed:http://example.com/feed.xml",
null,
null);
6 var httpURI =
ios.newURI(
"http://example.com/feed.xml",
null,
null);
9 ios.newURI(
"feed:https://example.com/feed.xml",
null,
null);
10 var httpsURI =
ios.newURI(
"https://example.com/feed.xml",
null,
null);
12 var feedChannel =
ios.newChannelFromURI(feedFeedURI,
null);
13 var httpChannel =
ios.newChannelFromURI(httpFeedURI,
null);
14 var httpsChannel =
ios.newChannelFromURI(httpsFeedURI,
null);
17 do_check_true(feedFeedURI.equals(feedChannel.originalURI));
18 do_check_true(httpFeedURI.equals(httpChannel.originalURI));
19 do_check_true(httpsFeedURI.equals(httpsChannel.originalURI));
22 do_check_true(httpURI.equals(feedChannel.URI));
23 do_check_true(httpURI.equals(httpChannel.URI));
24 do_check_true(httpsURI.equals(httpsChannel.URI));
29 var dataFeedURI =
ios.newURI(
"feed:data:text/xml,<rss/>",
null,
null);
30 do_throw(
"Not reached");
31 }
catch (e
if (e instanceof
Ci.nsIException &&
36 var ftpFeedURI =
ios.newURI(
"feed:ftp://example.com/feed.xml",
null,
null);
37 do_throw(
"Not reached");
38 }
catch (e
if (e instanceof
Ci.nsIException &&
43 var fileFeedURI =
ios.newURI(
"feed:file:///var/feed.xml",
null,
null);
44 do_throw(
"Not reached");
45 }
catch (e
if (e instanceof
Ci.nsIException &&
const NS_ERROR_MALFORMED_URI