diff options
Diffstat (limited to 'tests/unit/umask_test.ts')
-rw-r--r-- | tests/unit/umask_test.ts | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/unit/umask_test.ts b/tests/unit/umask_test.ts new file mode 100644 index 000000000..0e97f0d35 --- /dev/null +++ b/tests/unit/umask_test.ts @@ -0,0 +1,15 @@ +// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license. +import { assertEquals } from "./test_util.ts"; + +Deno.test( + { + ignore: Deno.build.os === "windows", + }, + function umaskSuccess() { + const prevMask = Deno.umask(0o020); + const newMask = Deno.umask(prevMask); + const finalMask = Deno.umask(); + assertEquals(newMask, 0o020); + assertEquals(finalMask, prevMask); + }, +); |