...
 
Commits (3)
......@@ -16,7 +16,7 @@ Current state:
```
ABCL works
ACL works
Clasp fails 2 Spartns tests (but no spartns-utils tests)
Clasp fails 2 Spartns tests (but no spartns-utils tests) * tested w/old version
CLISP works
Clozure works
CMUCL works (tested the 32bit binary on a 64bit platform; passes all tests)
......
......@@ -10,7 +10,7 @@ Features:
* Represents mappings from one dimension onto another using any scheme you want (there are three built-in schemes: array, hash and compressed-vector, but you can roll your own and plug it);
* Flexible: works with any data type;
* Heavily optimized: traversing the tensor can be extremely fast (in one specific situation -- traversing the tensor -- it was 10 times faster than a naive implementation in C++);
* Fairly portable: works with ABCL, ACL, Clisp, Clozure, CMUCL, ECL, GCL, SBCL, MKCL and XCL.
* Fairly portable: works with ABCL, ACL, Clisp, Clozure, CMUCL, ECL, GCL, SBCL, MKCL and XCL;
* Spartns is never released without going through regression tests (if a platform breaks and can't be supported, it will be clear in the release announcement);
* ASDF installable (thanks Slobodan Blazeski!);
* Easy to use, with introductory documentation (not only on-line);
......
......@@ -55,4 +55,5 @@ Tests:
+ Check if PACK is really working for several dimensions. (Currently the
tests verify that nothing breaks by using it, but we can't tell if it
really is shrinking all intermediate dimensions)
- Tests currently only print results. In order for the testing script
to be useful, do-tests.lisp should exit with a meaningful value
......@@ -3,23 +3,56 @@
# This script runs tests on all supported platforms
#
echo -n "tests: start... "
echo "- - - - -" > test-results.txt
## Associative array (Bash 4 feature):
declare -A implementations=(
["SBCL"]="sbcl --script"
["Clisp"]="clisp"
["ECL"]="ecl -load"
["GCL"]="GCL_ANSI=1 gcl -load"
['CCL']="ccl64 --load"
["ABCL"]="java -jar /home/jeronimo/pkg/abcl/dist/abcl.jar --batch --load"
# ["Clasp"]="/home/jeronimo/pkg/clasp/build/clasp --load"
# ["XCL"]="/home/jeronimo/pkg/lisp/xcl/xcl --load" XCL is currently not buildable
)
echo "- - - - -"
for name in "${!implementations[@]}"; do
echo "$name: "
${implementations["$name"]} do-tests.lisp;
echo "- - - - -"
done
echo -n " [SBCL] "
echo "SBCL: " >> test-results.txt
# --script does not load parachute
sbcl --load do-tests.lisp \
2>test-SBCL.log \
| grep 'tests>' >> test-results.txt
echo "- - - - -" >> test-results.txt
echo -n " [Clisp] "
echo "Clisp: " >> test-results.txt
# use pipe, otherwise Clisp gets confused about packages
clisp < do-tests.lisp \
2>test-clisp.log \
| grep 'tests>' >> test-results.txt
echo "- - - - -" >> test-results.txt
echo -n " [ECL] "
echo "ECL: " >> test-results.txt
ecl -load do-tests.lisp \
2>test-ecl.log \
| grep 'tests>' >> test-results.txt
echo "- - - - -" >> test-results.txt
# Need a newer ASDF in order to install Quicklisp, so I can load Parachute.
# echo " [GCL] "
# GCL_ANSI=1 gcl -load # no quicklisp
# echo "- - - - -" >> test-results.txt
echo -n " [CCL] "
echo "CCL: " >> test-results.txt
ccl64 --load /home/jeronimo/quicklisp/setup.lisp -e '(progn (ql:quickload "parachute") (load "do-tests.lisp"))'\
2>test-ccl.log \
| grep 'tests>' >> test-results.txt
echo "- - - - -" >> test-results.txt
echo -n " [ABCL] "
echo "ABCL: " >> test-results.txt
java -jar /home/jeronimo/pkg/abcl/dist/abcl.jar --batch --load do-tests.lisp \
2> test-abcl.log \
| grep 'tests>' >> test-results.txt
echo "- - - - -" >> test-results.txt
# Clasp fails to build on my machine
# ["Clasp"]="/home/jeronimo/pkg/clasp/build/clasp --load do-tests.lisp"
# XCL is currently not buildable
# ["XCL"]="/home/jeronimo/pkg/lisp/xcl/xcl --load do-tests.lisp"
echo "done."
(progn
(load "lisp-unit.lisp")
(load "spartns-packages.lisp")
(load "spartns-test-packages.lisp")
(load "utils.lisp")
(load "spartns.lisp")
(load "utils-test.lisp")
(load "tests.lisp")
(quit))
(load "spartns-packages.lisp")
(load "spartns-test-packages.lisp")
(load "utils.lisp")
(load "spartns.lisp")
(load "utils-tests.lisp")
(load "tests.lisp")
;; parachute supports three kinds of report:
;; - plain, in which each test produces an
;; output and returns a report object
;; - quiet, which only returns an object
;; which holds the number of tests performed
;; and wether there were any failures
;; - interactive, in which test failures will
;; trigger errors
(in-package :jp-utils-test)
(defvar utils-report nil)
(setf utils-report (parachute::test 'utils :report 'quiet))
(in-package :spartns-test)
(defvar main-report nil)
(setf main-report (parachute::test 'main :report 'quiet))
(princ '-----------------------------------------)
(terpri)
(in-package :common-lisp-user)
(format T "tests> utils: ~a~%" (parachute::summarize jp-utils-test::utils-report))
(format T "tests> main: ~a~%" (parachute::summarize spartns-test::main-report))
(quit)
......@@ -7,15 +7,17 @@
(in-package :cl-user)
(require 'parachute)
(defpackage #:jp-utils-test
(:use #:common-lisp
#:jp-utils
#:lisp-unit))
#:parachute))
(defpackage #:spartns-test
(:use #:common-lisp
#:lisp-unit
#:jp-utils
#:jp-utils-test
#:spartns))
#:spartns
#:parachute))
This diff is collapsed.
This diff is collapsed.