blob: ce3bbe1b1ce05e9d0ab8f2cd2757112e5f82e532 (
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
|
#!/bin/sh
# Check for requirements, run AIS tests if found.
#
test `id -ng` = "ais" || BADGROUP=yes
{ ps -u root | grep aisexec >/dev/null; } || NOAISEXEC=yes
if test -n "$BADGROUP" -o -n "$NOAISEXEC"; then
cat <<EOF
=========== WARNING: NOT RUNNING AIS TESTS ==============
Tests that depend on the openais library (used for clustering)
will not be run because:
EOF
test -n "$BADGROUP" && cat <<EOF
You do not appear to have you group ID set to "ais". Make ais your
primary group, or run "newgrp ais" before running the tests.
EOF
test -n "$NOAISEXEC" && cat <<EOF
The aisexec daemon is not running. Make sure /etc/ais/openais.conf
is a valid configuration and aisexec is run by root.
EOF
cat <<EOF
==========================================================
EOF
exit 0; # A warning, not a failure.
fi
FAILED=0
for test in `cat ais_tests`; do
./$test || FAILED=`expr $FAILED + 1`
done
exit $FAILED
|