clean up externals
[CommonLispStat.git] / external / ch-util / src / testharness.cl
blob623aeedaade01b33f74f7fdad634e3286c52cf12
1 ;;;
2 ;;; testharness.cl -- various lisp utilities for hash-tables
3 ;;;
4 ;;; Author: Cyrus Harmon <ch-lisp@bobobeach.com>
5 ;;; Time-stamp: <2005-07-01 08:11:52 sly>
6 ;;;
8 (in-package :ch-util)
10 (defparameter *verbose-test-results* nil)
12 (defstruct test-run
13 (tests 0)
14 (passed 0))
16 (defun run-test (f test-name run)
17 (if (funcall f)
18 (progn
19 (when *verbose-test-results*
20 (format t "~&Test ~A Succeeded" test-name))
21 (incf (test-run-passed run))
22 (incf (test-run-tests run)))
23 (progn
24 (format t "~&Test ~A Failed!" test-name)
25 (incf (test-run-tests run)))))