Commit 1ef5c959 authored by Robert Goldman's avatar Robert Goldman
Browse files

Modify test-running scripts to catch SERIOUS-CONDITIONs.

There are some serious conditions (e.g., STORAGE-CONDITION) that are not
ERRORs.  Previously, our test scripts only caught ERRORs, meaning that
if a lisp implementation encountered a non-ERROR SERIOUS-CONDITION in
the course of running the tests, odd behavior could result.  E.g.,
running in ECL we would drop into the debugger instead of exiting with a
non-zero exit status.
parent a6ed88c3
...@@ -373,23 +373,20 @@ is bound, write a message and exit on an error. If ...@@ -373,23 +373,20 @@ is bound, write a message and exit on an error. If
*asdf-test-debug* is true, enter the debugger." *asdf-test-debug* is true, enter the debugger."
(redirect-outputs) (redirect-outputs)
(let ((result (let ((result
(catch :asdf-test-done (catch :asdf-test-done
(handler-bind (handler-bind
((error (lambda (c) ((serious-condition
(ignore-errors (lambda (c)
(format *error-output* "~&TEST ABORTED: ~A~&" c)) (ignore-errors
(finish-outputs*) (format *error-output* "~&TEST ABORTED: ~A~&" c))
(cond (finish-outputs*)
(*debug-asdf* (unless *debug-asdf*
(format t "~&It's your baby, fix it!~%") (ignore-errors
(break)) (acall :print-condition-backtrace
(t c :count 69 :stream *error-output*))
(ignore-errors (leave-test "Script failed" 1)))))
(acall :print-condition-backtrace (funcall (or (asym :call-with-asdf-cache) 'funcall) thunk)
c :count 69 :stream *error-output*)) (leave-test "Script succeeded" 0)))))
(leave-test "Script failed" 1))))))
(funcall (or (asym :call-with-asdf-cache) 'funcall) thunk)
(leave-test "Script succeeded" 0)))))
(when *quit-when-done* (when *quit-when-done*
(exit-lisp result)))) (exit-lisp result))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment