diff --git a/test-suite/tests/sandbox.test b/test-suite/tests/sandbox.test index 96651a2b1..54fb79495 100644 --- a/test-suite/tests/sandbox.test +++ b/test-suite/tests/sandbox.test @@ -40,13 +40,17 @@ (with-test-prefix "time limit" (pass-if "0 busy loop" + (unless (defined? 'SIGALRM) (throw 'unsupported)) (call-with-time-limit 0 busy-loop (lambda () #t))) (pass-if "0.001 busy loop" + (unless (defined? 'SIGALRM) (throw 'unsupported)) (call-with-time-limit 0.001 busy-loop (lambda () #t))) (pass-if "0 sleep" + (unless (defined? 'SIGALRM) (throw 'unsupported)) (call-with-time-limit 0 (lambda () (usleep-loop #e1e6) #f) (lambda () #t))) (pass-if "0.001 sleep" + (unless (defined? 'SIGALRM) (throw 'unsupported)) (call-with-time-limit 0.001 (lambda () (usleep-loop #e1e6) #f) (lambda () #t)))) diff --git a/test-suite/tests/time.test b/test-suite/tests/time.test index b5c7dbc36..72ad5bb15 100644 --- a/test-suite/tests/time.test +++ b/test-suite/tests/time.test @@ -29,7 +29,9 @@ (for-each (lambda (t) (pass-if (list "in another thread after error" t) - (or (provided? 'threads) (throw 'unsupported)) + (unless (and (provided? 'threads) + (defined? 'alarm)) + (throw 'unsupported)) (alarm 5) (false-if-exception (gmtime t))