-
Notifications
You must be signed in to change notification settings - Fork 3
/
test.bash
executable file
·39 lines (31 loc) · 970 Bytes
/
test.bash
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
#!/usr/bin/env bash
# Need Bash >= 4.x for associative arrays
declare -A TEST_LIST=(
[basic/ret_zero.ll]="0"
[basic/array.ll]="15"
[basic/ptr.ll]="5"
[basic/ptrtoarray.ll]="0"
# math tests
[math/oneplusone.ll]="2"
[math/twotimestwo.ll]="4"
[math/fourdivtwo.ll]="2"
[math/threeminusone.ll]="2"
[math/math_stuff.ll]="0"
[math/comparison.ll]="5"
# branching tests
[branch/branch.ll]="2"
[branch/falsebranch.ll]="3"
[branch/nestedbranch.ll]="2"
# function tests
[functions/noargs.ll]="1"
[functions/playnice.ll]="1"
[functions/paramorder.ll]="1"
[functions/square.ll]="25"
[functions/addone.ll]="2"
)
echo "-------------------------"
echo "Testing blessedvirginmary"
echo "-------------------------"
parallel --link ./runtest.bash ::: ${!TEST_LIST[@]} ::: ${TEST_LIST[@]}
echo "-------------------------"
exit ${FAIL_NUM}