diff options
author | Asher Gomez <ashersaupingomez@gmail.com> | 2024-09-10 08:39:56 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-09 22:39:56 +0000 |
commit | a445ebd74fc4bb2a949828e155fcfe1d39d9f617 (patch) | |
tree | 0b97113f3d57a1f58aba1a2357061719d5ae2156 /tests/unit | |
parent | 064a73f7a08eb12d99fcdf8844e9ce5db62be78b (diff) |
BREAKING(fs): remove `Deno.fsync[Sync]()` (#25448)
Towards #22079
---------
Signed-off-by: Asher Gomez <ashersaupingomez@gmail.com>
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/sync_test.ts | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/tests/unit/sync_test.ts b/tests/unit/sync_test.ts deleted file mode 100644 index a683c7acb..000000000 --- a/tests/unit/sync_test.ts +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license. -import { assertEquals, DENO_FUTURE } from "./test_util.ts"; - -Deno.test( - { ignore: DENO_FUTURE, permissions: { read: true, write: true } }, - function fsyncSyncSuccess() { - const filename = Deno.makeTempDirSync() + "/test_fsyncSync.txt"; - using file = Deno.openSync(filename, { - read: true, - write: true, - create: true, - }); - const size = 64; - file.truncateSync(size); - Deno.fsyncSync(file.rid); - assertEquals(Deno.statSync(filename).size, size); - Deno.removeSync(filename); - }, -); - -Deno.test( - { ignore: DENO_FUTURE, permissions: { read: true, write: true } }, - async function fsyncSuccess() { - const filename = (await Deno.makeTempDir()) + "/test_fsync.txt"; - using file = await Deno.open(filename, { - read: true, - write: true, - create: true, - }); - const size = 64; - await file.truncate(size); - await Deno.fsync(file.rid); - assertEquals((await Deno.stat(filename)).size, size); - await Deno.remove(filename); - }, -); |