Bug 1541508 - Use Services.env in browser/ r=mossop

Differential Revision: https://phabricator.services.mozilla.com/D160136
This commit is contained in:
Barret Rennie
2022-11-25 19:09:06 +00:00
parent c4f38e393b
commit d1a2566d45
26 changed files with 53 additions and 122 deletions

View File

@@ -15,12 +15,9 @@ const INDEX_QUARANTINE_ERROR = 3;
add_setup(function() {
// AttributionCode._clearCache is only possible in a testing environment
let env = Cc["@mozilla.org/process/environment;1"].getService(
Ci.nsIEnvironment
);
env.set("XPCSHELL_TEST_PROFILE_DIR", "testing");
Services.env.set("XPCSHELL_TEST_PROFILE_DIR", "testing");
registerCleanupFunction(() => {
env.set("XPCSHELL_TEST_PROFILE_DIR", null);
Services.env.set("XPCSHELL_TEST_PROFILE_DIR", null);
});
});