Skip to content

Commit 29fb75c

Browse files
shymjmid
authored andcommitted
Add other error messages spotted on Windows and macOS
1 parent 47e65f4 commit 29fb75c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/sys/stm_tests.ml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,8 @@ struct
211211
| Sys_error s ->
212212
(s = (p complete_path) ^ ": Permission denied") ||
213213
(s = (p complete_path) ^ ": File exists" && mem_model fs complete_path) ||
214-
(s = (p complete_path) ^ ": No such file or directory" && not (mem_model fs path)) ||
214+
((s = (p complete_path) ^ ": No such file or directory"
215+
|| s = (p complete_path) ^ ": Invalid argument") && not (mem_model fs path)) ||
215216
if Sys.win32 && not (path_is_a_dir fs complete_path)
216217
then s = (p complete_path) ^ ": No such file or directory"
217218
else s = (p complete_path) ^ ": Not a directory"
@@ -223,6 +224,7 @@ struct
223224
| Error err ->
224225
(match err with
225226
| Sys_error s ->
227+
(s = (p complete_path) ^ ": Permission denied") ||
226228
(s = (p complete_path) ^ ": Directory not empty" && not (readdir_model fs complete_path = Some [])) ||
227229
(s = (p complete_path) ^ ": No such file or directory" && not (mem_model fs complete_path)) ||
228230
if Sys.win32 && not (path_is_a_dir fs complete_path) (* if not a directory *)

0 commit comments

Comments
 (0)