X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Ftest.lisp;h=aacb11e8236f61520c961a889526cfa46cc51362;hb=7df749a8a0381171ab005a3f284385ce39757277;hp=9190003a73cc78b18cfb017ec47ed58fd8fc1b43;hpb=8e2b8ea5671d45cd1b3efdd037af289200e6e0a8;p=fiveam.git diff --git a/src/test.lisp b/src/test.lisp index 9190003..aacb11e 100644 --- a/src/test.lisp +++ b/src/test.lisp @@ -50,13 +50,13 @@ FIXTURE specifies a fixtrue to wrap the body in. If PROFILE is T profiling information will be collected as well." (let* ((tmp (gensym)) (suite-arg (getf (cdr (ensure-list name)) :suite tmp)) - (suite (cond - ((eq tmp suite-arg) *suite*) - (t (get-test suite-arg))))) + (suite-form (cond + ((eq tmp suite-arg) '*suite*) + (t `(get-test ',suite-arg))))) (when (consp name) (remf (cdr name) :suite)) (destructuring-bind (name &key depends-on (compile-at :run-time) fixture profile) - (append (ensure-list name) (default-test-args suite)) + (ensure-list name) (declare (type (member :run-time :definition-time) compile-at)) (let ((description (if (stringp (car body)) (pop body) @@ -81,7 +81,7 @@ If PROFILE is T profiling information will be collected as well." :description ,description :depends-on ',depends-on :collect-profiling-info ,profile)) - (setf (gethash ',name (tests (get-test ',(name suite)))) ',name) + (setf (gethash ',name (tests ,suite-form)) ',name) (when *run-test-when-defined* (run! ',name)) ',name)))))