diff options
author | James Bradlee <post@jamesb.no> | 2022-05-31 10:42:44 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-31 17:42:44 +0900 |
commit | c41544ac7b502fbdb6c1ee96a604490b72eb7770 (patch) | |
tree | e2b855a0c722feddf170ffb11c2a7f756a7f1e56 /cli/tests | |
parent | d9ed5e905c25bd415b5e65649a44e0a1580e5ed1 (diff) |
feat(unstable): add Deno.getGid (#14528)
Diffstat (limited to 'cli/tests')
-rw-r--r-- | cli/tests/unit/os_test.ts | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cli/tests/unit/os_test.ts b/cli/tests/unit/os_test.ts index 6ed1126f1..b5ff6f29f 100644 --- a/cli/tests/unit/os_test.ts +++ b/cli/tests/unit/os_test.ts @@ -204,3 +204,13 @@ Deno.test({ permissions: { env: true } }, function getUid() { assert(uid > 0); } }); + +Deno.test({ permissions: { env: true } }, function getGid() { + if (Deno.build.os === "windows") { + assertEquals(Deno.getGid(), null); + } else { + const gid = Deno.getGid(); + assert(typeof gid === "number"); + assert(gid > 0); + } +}); |