mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-13 05:15:45 +00:00
Bug 1335645 - part 1 - Fix JS errors in test_reopen.js and test_file_partial_inputstream.js r=junior
MozReview-Commit-ID: 2QOdvACvW8z
This commit is contained in:
parent
64921de6f3
commit
57ede22306
@ -7,6 +7,8 @@
|
||||
// do_check_eq(a, b) to avoid outputting characters which confuse
|
||||
// the console
|
||||
|
||||
"use strict";
|
||||
|
||||
var CC = Components.Constructor;
|
||||
const BinaryInputStream = CC("@mozilla.org/binaryinputstream;1",
|
||||
"nsIBinaryInputStream",
|
||||
@ -34,6 +36,7 @@ function run_test()
|
||||
|
||||
let binaryStream = new BinaryInputStream(new_file_input_stream(binaryFile));
|
||||
test_file_data = "";
|
||||
let avail = 0;
|
||||
while ((avail = binaryStream.available()) > 0) {
|
||||
test_file_data += binaryStream.readBytes(avail);
|
||||
}
|
||||
|
@ -1,9 +1,15 @@
|
||||
// This testcase verifies that channels can't be reopened
|
||||
// See https://bugzilla.mozilla.org/show_bug.cgi?id=372486
|
||||
|
||||
"use strict";
|
||||
|
||||
Cu.import("resource://testing-common/httpd.js");
|
||||
Cu.import("resource://gre/modules/NetUtil.jsm");
|
||||
|
||||
const BinaryInputStream = Components.Constructor(
|
||||
"@mozilla.org/binaryinputstream;1", "nsIBinaryInputStream",
|
||||
"setInputStream");
|
||||
|
||||
const NS_ERROR_IN_PROGRESS = 0x804b000f;
|
||||
const NS_ERROR_ALREADY_OPENED = 0x804b0049;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user