The branch "master" has been updated in SBCL:
via 695bb17f0b3c5ae1680115f7c59ed625c2877084 (commit)
from ed1910efb36f71b5ebe33b5ffffd7195e15644de (commit)
- Log -----------------------------------------------------------------
commit 695bb17f0b3c5ae1680115f7c59ed625c2877084
Author: David Lichteblau <david@...>
Date: Tue Nov 13 18:13:08 2012 +0100
Forcibly fail frlock.1 on Windows by means of a timeout
Presumably due to windows sb-thread bugs, this test often hangs on
Windows. For now, establish a timeout, and mark the test as a known
failure on this platform.
---
contrib/sb-concurrency/sb-concurrency.asd | 19 +++++++++++++++++--
contrib/sb-concurrency/tests/test-frlock.lisp | 13 +++++++++++--
2 files changed, 28 insertions(+), 4 deletions(-)
diff --git a/contrib/sb-concurrency/sb-concurrency.asd b/contrib/sb-concurrency/sb-concurrency.asd
index ba901c8..913f078 100644
--- a/contrib/sb-concurrency/sb-concurrency.asd
+++ b/contrib/sb-concurrency/sb-concurrency.asd
@@ -41,5 +41,20 @@
(defmethod asdf:perform ((o asdf:test-op)
(c (eql (asdf:find-system :sb-concurrency-tests))))
- (or (funcall (intern "DO-TESTS" (find-package "SB-RT")))
- (error "~S failed" 'asdf:test-op)))
+ (multiple-value-bind (soft strict pending)
+ (funcall (intern "DO-TESTS" (find-package "SB-RT")))
+ (fresh-line)
+ (unless strict
+ #+sb-testing-contrib
+ ;; We create TEST-PASSED from a shell script if tests passed. But
+ ;; since the shell script only `touch'es it, we can actually create
+ ;; it ahead of time -- as long as we're certain that tests truly
+ ;; passed, hence the check for SOFT.
+ (when soft
+ (with-open-file (s #p"SYS:CONTRIB;SB-CONCURRENCY;TEST-PASSED"
+ :direction :output)
+ (dolist (pend pending)
+ (format s "Expected failure: ~A~%" pend))))
+ (warn "ignoring expected failures in test-op"))
+ (unless soft
+ (error "test-op failed with unexpected failures"))))
diff --git a/contrib/sb-concurrency/tests/test-frlock.lisp b/contrib/sb-concurrency/tests/test-frlock.lisp
index 466ce8a..dc38082 100644
--- a/contrib/sb-concurrency/tests/test-frlock.lisp
+++ b/contrib/sb-concurrency/tests/test-frlock.lisp
@@ -11,6 +11,12 @@
(in-package :sb-concurrency-test)
+(defmacro deftest* ((name &key fails-on) form &rest results)
+ `(progn
+ (when (sb-impl::featurep ',fails-on)
+ (pushnew ',name sb-rt::*expected-failures*))
+ (deftest ,name ,form ,@results)))
+
(defun test-frlocks (&key (reader-count 100) (read-count 1000000)
(outer-read-pause 0) (inner-read-pause 0)
(writer-count 10) (write-count 10000)
@@ -73,7 +79,10 @@
nil))))
(values (cdr w-e!) (cdr r-e!))))
-(deftest frlock.1
- (test-frlocks)
+(deftest* (frlock.1 :fails-on :win32)
+ (handler-case
+ (sb-ext:with-timeout 60 (test-frlocks))
+ (sb-ext:timeout (c)
+ (error "~A" c)))
nil
nil)
-----------------------------------------------------------------------
hooks/post-receive
--
SBCL
|