Bug 792808 - Change test_SpecialPowersExtension.html to import and instantiate XHRs from global properties rather than using Cc.createInstance(Ci.nsIXMLHttpRequest); r=mrbkap

MozReview-Commit-ID: JW37fmAuxE2

--HG--
extra : rebase_source : 4b2a3e05f619332f9fdeb42190e9253ad6e9a26d
This commit is contained in:
Thomas Wisniewski 2017-09-19 12:18:59 -04:00
Родитель 1966e88a4a
Коммит 16742d6e24
1 изменённых файлов: 2 добавлений и 3 удалений

Просмотреть файл

@ -92,9 +92,8 @@ function starttest(){
// Test the SpecialPowers wrapper.
//
// Try some basic stuff with XHR.
var xhr2 = SpecialPowers.Cc["@mozilla.org/xmlextras/xmlhttprequest;1"].createInstance(SpecialPowers.Ci.nsIXMLHttpRequest);
is(xhr2.readyState, XMLHttpRequest.UNSENT, "Should be able to get props off privileged objects");
let fp = SpecialPowers.Cc["@mozilla.org/filepicker;1"].createInstance(SpecialPowers.Ci.nsIFilePicker);
is(fp.mode, SpecialPowers.Ci.nsIFilePicker.modeOpen, "Should be able to get props off privileged objects");
var testURI = SpecialPowers.Cc['@mozilla.org/network/standard-url-mutator;1']
.createInstance(SpecialPowers.Ci.nsIURIMutator)
.setSpec("http://www.foobar.org/")