aboutsummaryrefslogtreecommitdiff
path: root/test/js/node/fs
diff options
context:
space:
mode:
Diffstat (limited to 'test/js/node/fs')
-rw-r--r--test/js/node/fs/fs.test.ts8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/js/node/fs/fs.test.ts b/test/js/node/fs/fs.test.ts
index 4cfe93dc9..8ea9522e1 100644
--- a/test/js/node/fs/fs.test.ts
+++ b/test/js/node/fs/fs.test.ts
@@ -2038,6 +2038,12 @@ it("test syscall errno, issue#4198", () => {
mkdirSync(path);
expect(() => mkdirSync(path)).toThrow("File or folder exists");
- expect(() => unlinkSync(path)).toThrow("Operation not permitted");
+ expect(() => unlinkSync(path)).toThrow(
+ {
+ ["darwin"]: "Operation not permitted",
+ ["linux"]: "Is a directory",
+ // TODO: windows
+ }[process.platform] as const,
+ );
rmdirSync(path);
});