-
Notifications
You must be signed in to change notification settings - Fork 160
/
test
executable file
·60 lines (55 loc) · 976 Bytes
/
test
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
#!/usr/bin/env bash
# Test everything that is automatable.
top="$(pwd)"
# make test
for t in \
c \
c_from_cpp \
c/extern \
c/static/function \
c/static/variable \
cpp \
cpp_from_c \
cpp/extern_const \
cpp/inline_variable \
gcc \
gcc/weak \
glibc \
linker/incremental_link \
linker/variable_address \
posix \
shared_library/basic \
shared_library/lib_lib_dependency \
shared_library/symbol_version \
; do
if ! make -C "$t" -j`nproc` test; then
echo "TEST FAILED: $t"
exit 1
fi
done
# make only
for t in \
c/interactive \
cpp/interactive \
glibc/interactive \
posix/curses \
posix/interactive \
posix/socket \
; do
if ! make -C "$t" -j`nproc`; then
echo "TEST FAILED: $t"
exit 1
fi
done
# ./test only
for t in \
scons \
; do
cd "${top}/${t}"
if ! ./test; then
echo "TEST FAILED: $t"
exit 1
fi
done
echo "ALL TESTS PASSED"
exit 0