Thu, 15 Jan 2015 21:03:48 +0100
Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)
1 // This is essentially a debug mode crashtest to make sure everything
2 // involved in a reload runs on the right thread. It relies on the
3 // assertions in necko.
5 var listener = {
6 onStartRequest: function test_onStartR(request, ctx) {
7 },
9 onDataAvailable: function test_ODA() {
10 do_throw("Should not get any data!");
11 },
13 onStopRequest: function test_onStopR(request, ctx, status) {
14 do_test_finished();
15 },
16 };
18 function run_test() {
19 var ios = Cc["@mozilla.org/network/io-service;1"].
20 getService(Ci.nsIIOService);
21 var chan = ios.newChannel("http://localhost:4444", "", null);
22 chan.loadFlags = Ci.nsIRequest.LOAD_FRESH_CONNECTION |
23 Ci.nsIChannel.LOAD_INITIAL_DOCUMENT_URI;
24 chan.QueryInterface(Ci.nsIHttpChannel);
25 chan.asyncOpen(listener, null);
26 do_test_pending();
27 }