From bdde8a36575f08ba22f46ac2377a5cb52b788ed8 Mon Sep 17 00:00:00 2001 From: Francois-Rene Rideau <tunes@google.com> Date: Mon, 14 Oct 2013 23:12:05 -0400 Subject: [PATCH] Don't print too many backtraces in asdf-pathname-test. --- test/asdf-pathname-test.script | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/test/asdf-pathname-test.script b/test/asdf-pathname-test.script index cda002c2..8c8ab984 100644 --- a/test/asdf-pathname-test.script +++ b/test/asdf-pathname-test.script @@ -108,12 +108,19 @@ failures) nil)))) +(defparameter *backtraces* 0) +(defparameter *max-backtraces* 2) + (defun test-file (file &key configuration (test-status *test-status*) (start-time 0)) (with-slots (system-count directory-count file-count system-failures directory-failures file-failures failures) test-status (incf file-count) (unless (block nil - (handler-bind ((error #'(lambda (c) (print-condition-backtrace c) (return nil)))) + (handler-bind ((error #'(lambda (c) + (incf *backtraces*) + (when (<= *backtraces* *max-backtraces*) + (print-condition-backtrace c)) + (return nil)))) (with-open-file (stream (component-pathname file) :direction :output :if-exists :supersede :if-does-not-exist :error) -- GitLab