summaryrefslogtreecommitdiff
path: root/std/node
diff options
context:
space:
mode:
authortokiedokie <thetokiedokie@gmail.com>2020-09-15 13:26:57 +0900
committerGitHub <noreply@github.com>2020-09-15 06:26:57 +0200
commit04d347225776ef81282740a55b55a45419644b7f (patch)
treef8076b2f84c96112cb6599d475e7df4c5d470346 /std/node
parentf457ff9157c845db08accd5905a2c1cbd7762b39 (diff)
refactor(cli/tests): change std_path to root_path in std_tests() (#7438)
Diffstat (limited to 'std/node')
-rw-r--r--std/node/process_test.ts3
1 files changed, 3 insertions, 0 deletions
diff --git a/std/node/process_test.ts b/std/node/process_test.ts
index d83a9dca7..4055dfd78 100644
--- a/std/node/process_test.ts
+++ b/std/node/process_test.ts
@@ -32,6 +32,8 @@ Deno.test({
fn() {
assertEquals(process.cwd(), Deno.cwd());
+ const currentDir = Deno.cwd(); // to unchange current directory after this test
+
const moduleDir = path.dirname(path.fromFileUrl(import.meta.url));
process.chdir(path.resolve(moduleDir, ".."));
@@ -40,6 +42,7 @@ Deno.test({
assert(process.cwd().match(/\Wnode$/));
process.chdir("..");
assert(process.cwd().match(/\Wstd$/));
+ process.chdir(currentDir); // to unchange current directory after this test
},
});