diff options
author | Daniel Llorens <daniel.llorens@bluewin.ch> | 2016-06-24 16:31:45 +0200 |
---|---|---|
committer | Daniel Llorens <daniel.llorens@bluewin.ch> | 2016-06-24 17:17:13 +0200 |
commit | 9687334ff52a2def369e7abb8563401351db9be7 (patch) | |
tree | f7caa8922e95ef59d4016418ac60cfe56e3f820c | |
parent | bd65845497110b179456d4bfdf26854791f0a822 (diff) |
On Darwin, skip tests that depend on setrlimit
On Darwin, setrlimit is ignored, and these tests do not terminate. There
doesn't seem to be another way to limit the memory allocated by a
process.
* test-suite/standalone/test-stack-overflow: Skip this test on Darwin.
* test-suite/standalone/test-out-of-memory: Skip this test on Darwin.
-rwxr-xr-x | test-suite/standalone/test-out-of-memory | 6 | ||||
-rwxr-xr-x | test-suite/standalone/test-stack-overflow | 7 |
2 files changed, 13 insertions, 0 deletions
diff --git a/test-suite/standalone/test-out-of-memory b/test-suite/standalone/test-out-of-memory index 2ae3ee69b..bda42cb44 100755 --- a/test-suite/standalone/test-out-of-memory +++ b/test-suite/standalone/test-out-of-memory @@ -9,6 +9,12 @@ exec guile -q -s "$0" "$@" ;; should run as part of an automated test suite. (exit 0)) +(when (string-ci= "darwin" (vector-ref (uname) 0)) + ;; setrlimits are ignored in OS X (tested on 10.9 and 10.10). Proceeding + ;; with the test would fill all available memory and probably end in a crash. + ;; See also test-stack-overflow. + (exit 77)) ; unresolved + (catch #t ;; Silence GC warnings. (lambda () diff --git a/test-suite/standalone/test-stack-overflow b/test-suite/standalone/test-stack-overflow index 3b979a99e..74bc7b874 100755 --- a/test-suite/standalone/test-stack-overflow +++ b/test-suite/standalone/test-stack-overflow @@ -9,6 +9,12 @@ exec guile -q -s "$0" "$@" ;; something we should run as part of an automated test suite. (exit 0)) +(when (string-ci= "darwin" (vector-ref (uname) 0)) + ;; setrlimits are ignored in OS X (tested on 10.9 and 10.10). Proceeding + ;; with the test would fill all available memory and probably end in a crash. + ;; See also test-stack-overflow. + (exit 77)) ; uresolved + ;; 100 MB. (define *limit* (* 100 1024 1024)) @@ -28,6 +34,7 @@ exec guile -q -s "$0" "$@" ;; Run the test a few times. The stack will only be enlarged and ;; relocated on the first one. + (test) (test) (test) |