diff options
author | Nayeem Rahman <muhammed.9939@gmail.com> | 2019-12-21 00:06:07 +0000 |
---|---|---|
committer | Ry Dahl <ry@tinyclouds.org> | 2019-12-20 19:06:07 -0500 |
commit | b7b0668c782dd4bc92237d91116f033e57536238 (patch) | |
tree | 74d9f68e17d35030254435c7f1c03e9227b27c4d /cli/js/os_test.ts | |
parent | e8d82a6348d4cf9fc6a023fe16bf75df7fea61b0 (diff) |
feat: Return null on error in Deno.dir() (#3531)
Diffstat (limited to 'cli/js/os_test.ts')
-rw-r--r-- | cli/js/os_test.ts | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/cli/js/os_test.ts b/cli/js/os_test.ts index e77678ec1..55a62792d 100644 --- a/cli/js/os_test.ts +++ b/cli/js/os_test.ts @@ -242,12 +242,7 @@ testPerm({ env: true }, function getDir(): void { if (r.shouldHaveValue) { assertNotEquals(Deno.dir(s.kind), ""); } else { - // if not support your platform. it should throw an error - assertThrows( - () => Deno.dir(s.kind), - Deno.DenoError, - `Could not get user ${s.kind} directory.` - ); + assertEquals(Deno.dir(s.kind), null); } } } |