packages for unittests moved to packages file. Or should these be moved to a separat...
[CommonLispStat.git] / src / unittests / unittests-regression.lisp
blob1112ac33f06381bcadb77e0463ca92ef06a568d3
1 ;;; -*- mode: lisp -*-
3 ;;; File: unittests-regression.lisp
4 ;;; Author: AJ Rossini <blindglobe@gmail.com>
5 ;;; Copyright: (c)2008, AJ Rossini.
6 ;;; License: BSD, see LICENSE.BSD file for details.
7 ;;; Purpose: unit-tests for regression; also make good examples
8 ;;; Time-stamp: <2008-10-31 17:33:20 tony>
9 ;;; Creation: <2008-05-13 17:16:07 tony>
11 ;;; What is this talk of 'release'? Klingons do not make software
12 ;;; 'releases'. Our software 'escapes', leaving a bloody trail of
13 ;;; designers and quality assurance people in its wake.
15 ;;; This organization and structure is new to the 21st Century
16 ;;; version.
18 ;; (in-package :cl-user)
19 ;; if needed, but need to set the ASDf path first...!
20 ;; (asdf:oos 'asdf:load-op :lift)
22 (in-package :lisp-stat-regression-unittests)
24 (deftestsuite lisp-stat-regression (lisp-stat) ())
26 ;;; TESTS
28 (addtest (lisp-stat-regression)
29 lin-regr1-fit-basis
30 (let ((m1 (regression-model iron aluminum :print nil)))
31 (ensure (> 0 (send m1 :basis)))))
33 (addtest (lisp-stat-regression)
34 lin-regr2-fit-basis
35 (let ((m1 (regression-model (list iron aluminum) absorbtion :print nil)))
36 (ensure (> 0 (send m1 :basis)))))
38 (addtest (lisp-stat-regression)
39 check-nonneg-fixnum
40 (ensure-error
41 (check-nonneg-fixnum -3)))
43 ;;;
44 ;; (run-tests)
45 ;; (describe (run-tests))