mirror of
https://github.com/HeyPuter/firefox.git
synced 2026-11-28 13:40:17 -10:00
18 lines
410 B
JavaScript
18 lines
410 B
JavaScript
"use strict";
|
|
|
|
let env = Cc["@mozilla.org/process/environment;1"].getService(Ci.nsIEnvironment);
|
|
|
|
add_task(async function test_getEnvironment() {
|
|
env.set("FOO", "BAR");
|
|
|
|
let environment = Subprocess.getEnvironment();
|
|
|
|
equal(environment.FOO, "BAR");
|
|
equal(environment.PATH, env.get("PATH"));
|
|
|
|
env.set("FOO", null);
|
|
|
|
environment = Subprocess.getEnvironment();
|
|
equal(environment.FOO || "", "");
|
|
});
|