Skip to content

Commit fee869b

Browse files
committed
test: accept macOS EPERM wording for box write denial
1 parent a071347 commit fee869b

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎tests/core/test_cli_args.nim‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,9 @@ suite "box subcommand (built-in sandwall)":
237237
let outside = getTempDir() / ("3code-box-leak-" & $epochTime().int64)
238238
let r = run(["box", "restrict", boxTmp, "--", "touch", outside])
239239
check r.code != 0
240-
check "Permission denied" in r.o
240+
# macOS Seatbelt reports the blocked syscall as EPERM ("Operation
241+
# not permitted") where Linux Landlock reports EACCES.
242+
check "Permission denied" in r.o or "Operation not permitted" in r.o
241243
check not fileExists(outside)
242244
else:
243245
skip()

0 commit comments

Comments
 (0)