Bug 534956 - Part 0 - rename xpcshell global variable for compatibility with add-on tests; r=rnewman

This commit is contained in:
Gregory Szorc 2011-12-07 17:12:58 -08:00
parent 6340fbecee
commit fd41c90381
2 changed files with 5 additions and 5 deletions

View File

@ -1,7 +1,7 @@
var gProfD;
let gSyncProfile;
do_load_httpd_js();
gProfD = do_get_profile();
gSyncProfile = do_get_profile();
Cu.import("resource://gre/modules/XPCOMUtils.jsm");

View File

@ -15,12 +15,12 @@ function setPlacesDatabase(aFileName) {
removePlacesDatabase();
_("Copying over places.sqlite.");
let file = do_get_file(aFileName);
file.copyTo(gProfD, kDBName);
file.copyTo(gSyncProfile, kDBName);
}
function removePlacesDatabase() {
_("Removing places.sqlite.");
let file = gProfD.clone();
let file = gSyncProfile.clone();
file.append(kDBName);
try {
file.remove(false);
@ -38,7 +38,7 @@ Svc.Obs.add("places-shutdown", function () {
function test_initial_state() {
// Mostly sanity checks our starting DB to make sure it's setup as we expect
// it to be.
let dbFile = gProfD.clone();
let dbFile = gSyncProfile.clone();
dbFile.append(kDBName);
let db = storageSvc.openUnsharedDatabase(dbFile);