Commit f5bd85bb authored by Liam M. Healy's avatar Liam M. Healy
Browse files

System-of-units tests

parent 808fed73
;; Tests of physical quantities
;; Liam Healy 2011-01-09 17:38:41EST tests.lisp
;; Time-stamp: <2011-06-23 13:41:18EDT physical-quantities.lisp>
;; Time-stamp: <2013-04-30 22:41:52EDT physical-quantities.lisp>
;; Copyright 2011 Liam M. Healy
;; Copyright 2011, 2013 Liam M. Healy
;; Distributed under the terms of the GNU General Public License
;; This program is free software: you can redistribute it and/or modify
......@@ -47,6 +47,22 @@
(lisp-unit:assert-numerical-equal #_0.45359237_kg #_1_pound)
(lisp-unit:assert-numerical-equal #_3600_s #_1_hour))
(lisp-unit:define-test system-of-units
(with-system-of-units (degree) (pqval #_10_degrees)))
(with-system-of-units* (*englishu*) (make-pq 1 'length))))
(let ((sysunits (nf-option :system-of-units)))
(set-default-system-of-units *cgsu*)
(pqval #_1_km)
(set-nf-options :system-of-units sysunits)))))
;;; These are all scalar units, i.e., the same units apply to each
;;; element of the array.
(lisp-unit:define-test grid-scalar-units
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment