Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of github.com:gwkkwg/lift

Conflicts:
	dev/definitions.lisp
	dev/utilities.lisp
  • Loading branch information...
commit 815f6f0c137dc9d1ea79b32572abd06cbfe1db60 2 parents 216ee9d + e5626bb
Gary King authored
Showing with 21 additions and 1 deletion.
  1. +21 −0 dev/lift.lisp
  2. +0 −1  dev/utilities.lisp
View
21 dev/lift.lisp
@@ -1510,6 +1510,27 @@ Test options are one of :setup, :teardown, :test, :tests, :documentation, :expor
:additional-data
`(,@(testsuite-log-data suite))))))
+(defmethod testsuite-log-data ((suite t))
+ nil)
+
+(defmethod testsuite-log-data :around ((suite t))
+ (multiple-value-bind (additional error?)
+ (ignore-errors (call-next-method))
+ (if error?
+ `(:error "error occured gathering additional data")
+ additional)))
+
+(defmethod test-case-teardown :around ((suite log-results-mixin) result)
+ (declare (ignore result))
+ (let ((problem (getf (test-data suite) :problem)))
+ (unless (and problem (typep problem 'test-error-mixin))
+ (generate-log-entry
+ nil
+ (getf (test-data suite) :seconds)
+ (getf (test-data suite) :conses)
+ :additional-data
+ `(,@(testsuite-log-data suite))))))
+
;;?? might be "cleaner" with a macrolet (cf. lift-result)
(defun lift-property (name)
(when *current-test*
View
1  dev/utilities.lisp
@@ -502,4 +502,3 @@ if `putative-pair` is a cons cell with a non-nil cdr."
(format nil "~a" thing))
(t
thing)))
-
Please sign in to comment.
Something went wrong with that request. Please try again.