5 import Tests.Cube as TC
6 import Tests.FunctionValues
9 import Tests.Tetrahedron as TT
11 -- The list of HUnit tests.
12 test_suite = TestList (concat [function_values_tests,
25 let qc_args = stdArgs { maxSuccess = 100,
30 putStrLn "\nGrid Tests\n"
32 putStrLn "\nCube Tests\n"
34 putStr "prop_all_volumes_positive... "
35 quickCheckWith qc_args prop_all_volumes_positive
37 -- putStr "prop_tetrahedron0_volumes_exact... "
38 -- quickCheckWith qc_args prop_tetrahedron0_volumes_exact
40 -- putStr "prop_tetrahedron1_volumes_exact... "
41 -- quickCheckWith qc_args prop_tetrahedron1_volumes_exact
43 -- putStr "prop_tetrahedron2_volumes_exact... "
44 -- quickCheckWith qc_args prop_tetrahedron2_volumes_exact
46 -- putStr "prop_tetrahedron3_volumes_exact... "
47 -- quickCheckWith qc_args prop_tetrahedron3_volumes_exact
49 -- putStr "prop_tetrahedron4_volumes_exact... "
50 -- quickCheckWith qc_args prop_tetrahedron4_volumes_exact
52 -- putStr "prop_tetrahedron4_volumes_exact... "
53 -- quickCheckWith qc_args prop_tetrahedron4_volumes_exact
55 -- putStr "prop_tetrahedron5_volumes_exact... "
56 -- quickCheckWith qc_args prop_tetrahedron5_volumes_exact
58 -- putStr "prop_tetrahedron6_volumes_exact... "
59 -- quickCheckWith qc_args prop_tetrahedron6_volumes_exact
61 -- putStr "prop_tetrahedron7_volumes_exact... "
62 -- quickCheckWith qc_args prop_tetrahedron7_volumes_exact
64 putStr "prop_tetrahedron0_volumes_positive... "
65 quickCheckWith qc_args prop_tetrahedron0_volumes_positive
67 putStr "prop_tetrahedron1_volumes_positive... "
68 quickCheckWith qc_args prop_tetrahedron1_volumes_positive
70 putStr "prop_tetrahedron2_volumes_positive... "
71 quickCheckWith qc_args prop_tetrahedron2_volumes_positive
73 putStr "prop_tetrahedron3_volumes_positive... "
74 quickCheckWith qc_args prop_tetrahedron3_volumes_positive
76 putStr "prop_tetrahedron4_volumes_positive... "
77 quickCheckWith qc_args prop_tetrahedron4_volumes_positive
79 putStr "prop_tetrahedron5_volumes_positive... "
80 quickCheckWith qc_args prop_tetrahedron5_volumes_positive
82 putStr "prop_tetrahedron6_volumes_positive... "
83 quickCheckWith qc_args prop_tetrahedron6_volumes_positive
85 putStr "prop_tetrahedron7_volumes_positive... "
86 quickCheckWith qc_args prop_tetrahedron7_volumes_positive
88 putStr "prop_tetrahedron8_volumes_positive... "
89 quickCheckWith qc_args prop_tetrahedron8_volumes_positive
91 putStr "prop_tetrahedron9_volumes_positive... "
92 quickCheckWith qc_args prop_tetrahedron9_volumes_positive
94 putStr "prop_tetrahedron10_volumes_positive... "
95 quickCheckWith qc_args prop_tetrahedron10_volumes_positive
97 putStr "prop_tetrahedron11_volumes_positive... "
98 quickCheckWith qc_args prop_tetrahedron11_volumes_positive
100 putStr "prop_tetrahedron12_volumes_positive... "
101 quickCheckWith qc_args prop_tetrahedron12_volumes_positive
103 putStr "prop_tetrahedron13_volumes_positive... "
104 quickCheckWith qc_args prop_tetrahedron13_volumes_positive
106 putStr "prop_tetrahedron14_volumes_positive... "
107 quickCheckWith qc_args prop_tetrahedron14_volumes_positive
109 putStr "prop_tetrahedron15_volumes_positive... "
110 quickCheckWith qc_args prop_tetrahedron15_volumes_positive
112 putStr "prop_tetrahedron16_volumes_positive... "
113 quickCheckWith qc_args prop_tetrahedron16_volumes_positive
115 putStr "prop_tetrahedron17_volumes_positive... "
116 quickCheckWith qc_args prop_tetrahedron17_volumes_positive
118 putStr "prop_tetrahedron18_volumes_positive... "
119 quickCheckWith qc_args prop_tetrahedron18_volumes_positive
121 putStr "prop_tetrahedron19_volumes_positive... "
122 quickCheckWith qc_args prop_tetrahedron19_volumes_positive
124 putStr "prop_tetrahedron20_volumes_positive... "
125 quickCheckWith qc_args prop_tetrahedron20_volumes_positive
127 putStr "prop_tetrahedron21_volumes_positive... "
128 quickCheckWith qc_args prop_tetrahedron21_volumes_positive
130 putStr "prop_tetrahedron22_volumes_positive... "
131 quickCheckWith qc_args prop_tetrahedron22_volumes_positive
133 putStr "prop_tetrahedron23_volumes_positive... "
134 quickCheckWith qc_args prop_tetrahedron23_volumes_positive
136 putStr "prop_v0_all_equal... "
137 quickCheckWith qc_args prop_v0_all_equal
139 -- putStrLn "\np. 78, (2.5)\n"
141 -- putStr "prop_cijk1_identity... "
142 -- quickCheckWith qc_args prop_cijk1_identity
145 -- putStrLn "\np. 79, (2.6)\n"
147 putStr "prop_c0120_identity1... "
148 quickCheckWith qc_args TC.prop_c0120_identity1
150 putStr "prop_c0120_identity2... "
151 quickCheckWith qc_args TC.prop_c0120_identity2
153 putStr "prop_c0120_identity3... "
154 quickCheckWith qc_args TC.prop_c0120_identity3
156 putStr "prop_c0120_identity4... "
157 quickCheckWith qc_args TC.prop_c0120_identity4
159 putStr "prop_c0120_identity5... "
160 quickCheckWith qc_args TC.prop_c0120_identity5
162 putStr "prop_c0120_identity6... "
163 quickCheckWith qc_args TC.prop_c0120_identity6
165 putStr "prop_c0210_identity1... "
166 quickCheckWith qc_args TC.prop_c0210_identity1
168 putStr "prop_c0300_identity1... "
169 quickCheckWith qc_args TC.prop_c0300_identity1
171 putStr "prop_c1110_identity... "
172 quickCheckWith qc_args TC.prop_c1110_identity
174 putStr "prop_c1200_identity1... "
175 quickCheckWith qc_args TC.prop_c1200_identity1
177 putStr "prop_c2100_identity1... "
178 quickCheckWith qc_args TC.prop_c2100_identity1
180 putStrLn "\np. 79, (2.7)\n"
182 putStr "prop_c0102_identity1... "
183 quickCheckWith qc_args TC.prop_c0102_identity1
185 putStr "prop_c0201_identity1... "
186 quickCheckWith qc_args TC.prop_c0201_identity1
188 putStr "prop_c0300_identity2... "
189 quickCheckWith qc_args TC.prop_c0300_identity2
191 putStr "prop_c1101_identity... "
192 quickCheckWith qc_args TC.prop_c1101_identity
194 putStr "prop_c1200_identity2... "
195 quickCheckWith qc_args TC.prop_c1200_identity2
197 putStr "prop_c2100_identity2... "
198 quickCheckWith qc_args TC.prop_c2100_identity2
200 putStrLn "\np. 79, (2.8)\n"
202 putStr "prop_t0_shares_edge_with_t6... "
203 quickCheckWith qc_args prop_t0_shares_edge_with_t6
205 putStr "prop_c3000_identity... "
206 quickCheckWith qc_args TC.prop_c3000_identity
208 -- putStr "prop_c2010_identity... "
209 -- quickCheckWith qc_args TC.prop_c2010_identity
211 -- putStr "prop_c2001_identity... "
212 -- quickCheckWith qc_args TC.prop_c2001_identity
214 -- putStr "prop_c1020_identity... "
215 -- quickCheckWith qc_args TC.prop_c1020_identity
217 -- putStr "prop_c1002_identity... "
218 -- quickCheckWith qc_args TC.prop_c1002_identity
220 -- putStr "prop_c1011_identity... "
221 -- quickCheckWith qc_args TC.prop_c1011_identity
223 -- putStrLn "\np. 80, (2.9)\n"
225 -- putStr "prop_c0120_identity2... "
226 -- quickCheckWith qc_args TF.prop_c0120_identity2
228 -- putStr "prop_c0102_identity2... "
229 -- quickCheckWith qc_args TF.prop_c0102_identity2
231 -- putStr "prop_c0111_identity... "
232 -- quickCheckWith qc_args TF.prop_c0111_identity
234 -- putStr "prop_c0210_identity2... "
235 -- quickCheckWith qc_args TF.prop_c0210_identity2
237 -- putStr "prop_c0201_identity2... "
238 -- quickCheckWith qc_args TF.prop_c0201_identity2
240 -- putStr "prop_c0300_identity3... "
241 -- quickCheckWith qc_args TF.prop_c0300_identity3
244 putStrLn "\nMisc Tests\n"
246 putStr "prop_factorial_greater... "
247 quickCheckWith qc_args prop_factorial_greater
249 putStrLn "\nTetrahedron Tests\n"
251 putStr "prop_b0_v0_always_unity... "
252 quickCheckWith qc_args prop_b0_v0_always_unity
254 putStr "prop_b0_v1_always_zero... "
255 quickCheckWith qc_args prop_b0_v1_always_zero
257 putStr "prop_b0_v2_always_zero... "
258 quickCheckWith qc_args prop_b0_v2_always_zero
260 putStr "prop_b0_v3_always_zero... "
261 quickCheckWith qc_args prop_b0_v3_always_zero
263 putStr "prop_b1_v1_always_unity... "
264 quickCheckWith qc_args prop_b1_v1_always_unity
266 putStr "prop_b1_v0_always_zero... "
267 quickCheckWith qc_args prop_b1_v0_always_zero
269 putStr "prop_b1_v2_always_zero... "
270 quickCheckWith qc_args prop_b1_v2_always_zero
272 putStr "prop_b1_v3_always_zero... "
273 quickCheckWith qc_args prop_b1_v3_always_zero
275 putStr "prop_b2_v2_always_unity... "
276 quickCheckWith qc_args prop_b2_v2_always_unity
278 putStr "prop_b2_v0_always_zero... "
279 quickCheckWith qc_args prop_b2_v0_always_zero
281 putStr "prop_b2_v1_always_zero... "
282 quickCheckWith qc_args prop_b2_v1_always_zero
284 putStr "prop_b2_v3_always_zero... "
285 quickCheckWith qc_args prop_b2_v3_always_zero
287 putStr "prop_b3_v3_always_unity... "
288 quickCheckWith qc_args prop_b3_v3_always_unity
290 putStr "prop_b3_v0_always_zero... "
291 quickCheckWith qc_args prop_b3_v0_always_zero
293 putStr "prop_b3_v1_always_zero... "
294 quickCheckWith qc_args prop_b3_v1_always_zero
296 putStr "prop_b3_v2_always_zero... "
297 quickCheckWith qc_args prop_b3_v2_always_zero
299 putStrLn "\np. 78, (2.4)\n"
301 putStr "prop_c3000_identity... "
302 quickCheckWith qc_args TT.prop_c3000_identity
304 putStr "prop_c2100_identity... "
305 quickCheckWith qc_args TT.prop_c2100_identity
307 putStr "prop_c1110_identity... "
308 quickCheckWith qc_args TT.prop_c1110_identity
311 putStrLn "\nCardinal Tests\n"
313 putStr "prop_ccwx_rotation_changes_direction... "
314 quickCheckWith qc_args prop_ccwx_rotation_changes_direction
316 putStr "prop_cwx_rotation_changes_direction... "
317 quickCheckWith qc_args prop_cwx_rotation_changes_direction
319 putStr "prop_ccwy_rotation_changes_direction... "
320 quickCheckWith qc_args prop_ccwy_rotation_changes_direction
322 putStr "prop_cwy_rotation_changes_direction... "
323 quickCheckWith qc_args prop_cwy_rotation_changes_direction
325 putStr "prop_ccwz_rotation_changes_direction... "
326 quickCheckWith qc_args prop_ccwz_rotation_changes_direction
328 putStr "prop_cwz_rotation_changes_direction... "
329 quickCheckWith qc_args prop_cwz_rotation_changes_direction
331 putStr "prop_ccwx_rotation_result_unique... "
332 quickCheckWith qc_args prop_ccwx_rotation_result_unique
334 putStr "prop_cwx_rotation_result_unique... "
335 quickCheckWith qc_args prop_cwx_rotation_result_unique
337 putStr "prop_ccwy_rotation_result_unique... "
338 quickCheckWith qc_args prop_ccwy_rotation_result_unique
340 putStr "prop_cwy_rotation_result_unique... "
341 quickCheckWith qc_args prop_cwy_rotation_result_unique
343 putStr "prop_ccwz_rotation_result_unique... "
344 quickCheckWith qc_args prop_ccwz_rotation_result_unique
346 putStr "prop_cwz_rotation_result_unique... "
347 quickCheckWith qc_args prop_cwz_rotation_result_unique
349 putStr "prop_four_cwx_is_identity... "
350 quickCheckWith qc_args prop_four_cwx_is_identity
352 putStr "prop_four_ccwx_is_identity... "
353 quickCheckWith qc_args prop_four_ccwx_is_identity
355 putStr "prop_four_cwy_is_identity... "
356 quickCheckWith qc_args prop_four_cwy_is_identity
358 putStr "prop_four_ccwy_is_identity... "
359 quickCheckWith qc_args prop_four_ccwy_is_identity
361 putStr "prop_four_cwz_is_identity... "
362 quickCheckWith qc_args prop_four_cwz_is_identity
364 putStr "prop_four_ccwz_is_identity... "
365 quickCheckWith qc_args prop_four_ccwz_is_identity