X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fsuite.lisp;h=14427c64482c1807af0103ab7617ff0971a2f833;hb=77155f18a3fd45a228f240599174098aa5751ce3;hp=e7aab24ff3cc8bf085f62ee16a40bec3481ab0b5;hpb=b6937ebfdbd276ec7e332ceade0697184904e4e1;p=fiveam.git diff --git a/src/suite.lisp b/src/suite.lisp index e7aab24..14427c6 100644 --- a/src/suite.lisp +++ b/src/suite.lisp @@ -23,12 +23,17 @@ IN (a symbol), if provided, causes this suite te be nested in the suite named by IN. NB: This macro is built on top of make-suite, as such it, like make-suite, will overrwrite any existing suite named NAME." - `(progn + `(eval-when (:compile-toplevel :load-toplevel :execute) (make-suite ',name - ,@(when description `(:description ,description)) - ,@(when in `(:in ',in))) + ,@(when description `(:description ,description)) + ,@(when in `(:in ',in))) ',name)) +(defmacro def-suite* (name &rest def-suite-args) + `(progn + (def-suite ,name ,@def-suite-args) + (in-suite ,name))) + (defun make-suite (name &key description in) "Create a new test suite object. @@ -59,7 +64,8 @@ after the execution of this form are, unless specified otherwise, in the test-suite named SUITE-NAME. See also: DEF-SUITE *SUITE*" - `(%in-suite ,suite-name)) + `(eval-when (:compile-toplevel :load-toplevel :execute) + (%in-suite ,suite-name))) (defmacro in-suite* (suite-name &key in) "Just like in-suite, but silently creates missing suites."