blob: ec71583c5115001cec0bf56a57db302f7ec0f91e (
plain)
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
|
#!/bin/bash
# create temporary symlink to workaround missing oldfind
ln -s /usr/bin/find /tmp/oldfind
# make oldfind visible
export PATH="/tmp:${PATH}"
export built_programs="find xargs locate updatedb"
# this gets substituted by sed during build
export VERSION="__run_ptest_version__"
# define missing functions for tests/init.sh
fu_path_prepend_ () {
path_prepend_ $@
}
print_ver_ () {
:
}
skip_if_root_ () {
[ $(id -u) = 0 ] && exit 77;
}
require_root_ () {
[ $(id -u) = 0 ] || exit 77;
}
expensive_ () {
:
}
export -f fu_path_prepend_
export -f print_ver_
export -f skip_if_root_
export -f require_root_
export -f expensive_
for f in tests/*/*.sh; do
bash $f ;
case $? in
0 )
echo -n "PASS";;
77 )
echo -n "SKIP";;
* )
echo -n "FAIL";;
esac
echo ": $f"
done
#remove symlink
rm -f /tmp/oldfind
echo
|