1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-23 15:16:54 -05:00
denoland-deno/cli/tests/unit/umask_test.ts

16 lines
411 B
TypeScript
Raw Normal View History

// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "./test_util.ts";
2020-03-10 15:11:27 -04:00
Deno.test(
2020-03-10 15:11:27 -04:00
{
ignore: Deno.build.os === "windows",
2020-03-10 15:11:27 -04:00
},
function umaskSuccess() {
2020-03-10 15:11:27 -04:00
const prevMask = Deno.umask(0o020);
const newMask = Deno.umask(prevMask);
const finalMask = Deno.umask();
assertEquals(newMask, 0o020);
assertEquals(finalMask, prevMask);
},
2020-03-10 15:11:27 -04:00
);