diff options
Diffstat (limited to 'cli/tests/unit/tty_test.ts')
-rw-r--r-- | cli/tests/unit/tty_test.ts | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/cli/tests/unit/tty_test.ts b/cli/tests/unit/tty_test.ts index 2f13dd739..dd492aa36 100644 --- a/cli/tests/unit/tty_test.ts +++ b/cli/tests/unit/tty_test.ts @@ -1,9 +1,9 @@ // Copyright 2018-2021 the Deno authors. All rights reserved. MIT license. -import { assert, assertThrows, unitTest } from "./test_util.ts"; +import { assert, assertThrows } from "./test_util.ts"; // Note tests for Deno.setRaw is in integration tests. -unitTest({ permissions: { read: true } }, function consoleSizeFile() { +Deno.test({ permissions: { read: true } }, function consoleSizeFile() { const file = Deno.openSync("cli/tests/testdata/hello.txt"); assertThrows(() => { Deno.consoleSize(file.rid); @@ -11,21 +11,21 @@ unitTest({ permissions: { read: true } }, function consoleSizeFile() { file.close(); }); -unitTest(function consoleSizeError() { +Deno.test(function consoleSizeError() { assertThrows(() => { // Absurdly large rid. Deno.consoleSize(0x7fffffff); }, Deno.errors.BadResource); }); -unitTest({ permissions: { read: true } }, function isatty() { +Deno.test({ permissions: { read: true } }, function isatty() { // CI not under TTY, so cannot test stdin/stdout/stderr. const f = Deno.openSync("cli/tests/testdata/hello.txt"); assert(!Deno.isatty(f.rid)); f.close(); }); -unitTest(function isattyError() { +Deno.test(function isattyError() { let caught = false; try { // Absurdly large rid. |