... In RT, use the list of expected test failures not just for
debugging output, but return as a primary result only whether
there are unexpected failures, with additional result values for
details on expected failures.
... Tweak make-target-contrib.sh so that the `test-passed' file, if
non-empty, can indicate a `successful' build of the contrib with
only known failures.
This mechanism is meant to follow in the footsteps of SBCL's main
test suite's mechanism for known failures, and is arguably not in
the original spirit of contribs as user contributions that must
build perfectly or fail to install entirely. However, for parts of
contrib/ which are very commonly used as a part of SBCL, it is hoped
that this new mechanism will aid work toward bug fixes in those
contribs rather than de-emphasize it.
$(SBCL) --eval '(defvar *system* "$(SYSTEM)")' --load ../asdf-stub.lisp --eval '(exit)'
test: all
- echo "(asdf:operate (quote asdf:load-op) :$(SYSTEM))" \
+ echo "(pushnew :sb-testing-contrib *features*)" \
+ "(asdf:operate (quote asdf:load-op) :$(SYSTEM))" \
"(asdf:operate (quote asdf:test-op) :$(SYSTEM))" | \
$(SBCL) --eval '(load "../asdf/asdf")'
(in-package :sb-bsd-sockets-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)))
+
;;; a real address
(deftest make-inet-address
(equalp (make-inet-address "127.0.0.1") #(127 0 0 1))
~:@(~{~<~% ~1:;~S~>~
~^, ~}~)."
(length new-failures)
- new-failures)))
- ))
+ new-failures)))))
(finish-output s)
- (null pending))))
+ (values (null new-failures) (null pending) pending))))
fi | tee output/building-contrib.`basename $i`
done
+# Otherwise report expected failures:
+HEADER_HAS_BEEN_PRINTED=false
+for dir in contrib/*; do
+ f="$dir/test-passed"
+ if test -f "$f" && grep -i fail "$f" >/dev/null; then
+ if ! $HEADER_HAS_BEEN_PRINTED; then
+ cat <<EOF
+
+Note: Test suite failures which are expected for this combination of
+platform and features have been ignored:
+EOF
+ HEADER_HAS_BEEN_PRINTED=true
+ fi
+ echo " $dir"
+ (unset IFS; while read line; do echo " $line"; done <"$f")
+ fi
+done
+
# Sometimes people used to see the "No tests failed." output from the last
# DEFTEST in contrib self-tests and think that's all that is. So...
HEADER_HAS_BEEN_PRINTED=false