summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gran <spk121@yahoo.com>2022-09-20 19:33:55 -0700
committerMichael Gran <spk121@yahoo.com>2022-09-20 19:50:14 -0700
commit426ed4068afaf9d134a90f25b0f5c84f4fe7df77 (patch)
treea8fe6db3e0732c846b9e4ecf21871b61687d2f83
parent775149f0f55d8cdb9543a1d10d6835ad9e5ce0c7 (diff)
downloadguile-426ed4068afaf9d134a90f25b0f5c84f4fe7df77.tar.gz
in ftw test, skip EACCESS test on MinGW
MinGW ACL-based permissions don't follow POSIX standard, so 'chmod' has unexpected behavior. * test-suite/tests/ftw.test (mingw?): new define ("file system fold: EACCES"): skip test on MinGW
-rw-r--r--test-suite/tests/ftw.test12
1 files changed, 9 insertions, 3 deletions
diff --git a/test-suite/tests/ftw.test b/test-suite/tests/ftw.test
index 454013a29..c35cba28b 100644
--- a/test-suite/tests/ftw.test
+++ b/test-suite/tests/ftw.test
@@ -23,6 +23,8 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-26))
+(define mingw?
+ (string-contains %host-type "-mingw32"))
;; the procedure-source checks here ensure the vector indexes we write match
;; what ice-9/posix.scm stat:dev and stat:ino do (which in turn match
@@ -238,9 +240,13 @@
(let ((name (string-append %top-builddir "/test-EACCES")))
(pass-if-equal "EACCES"
`((error ,name ,EACCES))
- (if (and (defined? 'getuid) (zero? (getuid)))
- ;; When run as root, this test would fail because root can
- ;; list the contents of #o000 directories.
+ (if (or (and (defined? 'getuid) (zero? (getuid)))
+ ;; When run as root, this test would fail because root can
+ ;; list the contents of #o000 directories.
+ mingw?
+ ;; MinGW uses ACLs for directory control, which
+ ;; chmod doesn't emulate.
+ )
(throw 'unresolved)
(with-file-tree %top-builddir '(directory "test-EACCES" #o000
(("a") ("b")))