-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathrun-tests.sh
executable file
·158 lines (139 loc) · 3.77 KB
/
run-tests.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
#!/bin/bash
FASL_CACHE=$HOME/.cache/common-lisp
echo "Test results" > test-results
# ensure we are building everything fresh
find $FASL_CACHE -name \*modf -exec rm -r {} \;
if which sbcl
then
sbcl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "sbcl: ~A~%" stefil:*last-test-result*))
EOF
fi
# cmucl
if which lisp
then
lisp <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "cmucl: ~A~%" stefil:*last-test-result*))
(quit)
EOF
fi
if which ccl
then
ccl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ccl: ~A~%" stefil:*last-test-result*))
EOF
fi
if which ccl64
then
ccl64 <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ccl64: ~A~%" stefil:*last-test-result*))
EOF
fi
if which clisp
then
clisp <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "clisp: ~A~%" stefil:*last-test-result*))
EOF
fi
if which ecl
then
ecl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ecl: ~A~%" stefil:*last-test-result*))
EOF
fi
if which abcl
then
abcl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "abcl: ~A~%" stefil:*last-test-result*))
EOF
fi
# Now run again to test what happens if the library is loaded from FASL files
# instead of compiled fresh
echo >> test-results
echo Testing the compiled library: >> test-results
if which sbcl
then
sbcl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "sbcl: ~A~%" stefil:*last-test-result*))
EOF
fi
# cmucl
if which lisp
then
lisp <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "cmucl: ~A~%" stefil:*last-test-result*))
(quit)
EOF
fi
if which ccl
then
ccl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ccl: ~A~%" stefil:*last-test-result*))
EOF
fi
if which ccl64
then
ccl64 <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ccl64: ~A~%" stefil:*last-test-result*))
EOF
fi
if which clisp
then
clisp <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "clisp: ~A~%" stefil:*last-test-result*))
EOF
fi
if which ecl
then
ecl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "ecl: ~A~%" stefil:*last-test-result*))
EOF
fi
if which abcl
then
abcl <<EOF
(ql:quickload :modf-test)
(stefil:without-debugging (modf-test:run-tests))
(with-open-file (out #p"test-results" :if-exists :append :direction :output)
(format out "abcl: ~A~%" stefil:*last-test-result*))
EOF
fi