X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=example.lisp;h=599d3b243fb4ce35a7cb1bdf1d9c5952fba554c1;hb=064f9491744e1c746a9164886cb9000463ba458f;hp=837906b713cee0fa2945501a33430bd1f6697bab;hpb=381a23bb7ab8dd206bcd430ce9c7ee9c53e52f13;p=xlunit.git diff --git a/example.lisp b/example.lisp index 837906b..599d3b2 100644 --- a/example.lisp +++ b/example.lisp @@ -2,7 +2,7 @@ ;;;; ************************************************************************* ;;;; FILE IDENTIFICATION ;;;; -;;;; ID: $Id: example.lisp,v 1.6 2003/08/04 17:04:49 kevin Exp $ +;;;; ID: $Id$ ;;;; Purpose: Example file for XLUnit ;;;; ;;;; ************************************************************************* @@ -32,19 +32,20 @@ (setf (numbera tcase) 2) (setf (numberb tcase) 3)) -(def-test-method test-addition ((test math-test-case)) + +(def-test-method test-addition ((test math-test-case) :run nil) (let ((result (+ (numbera test) (numberb test)))) (assert-true (= result 5)))) -(def-test-method test-subtraction ((test math-test-case)) +(def-test-method test-subtraction ((test math-test-case) :run nil) (let ((result (- (numberb test) (numbera test)))) (assert-equal result 1))) ;;; This method is meant to signal a failure -(def-test-method test-subtraction-2 ((test math-test-case)) +(def-test-method test-subtraction-2 ((test math-test-case) :run nil) (let ((result (- (numbera test) (numberb test)))) - (assert-equal result 1))) + (assert-equal result 1 "This is meant to failure"))) ;;;; Finally we can run our test suite and see how it performs. -(textui-test-run (make-instance 'math-test-case)) +(textui-test-run (get-suite math-test-case))