aboutsummaryrefslogtreecommitdiff
path: root/scripts/randomtest.loop
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-05-10 04:16:43 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2010-05-10 04:16:43 +0200
commitff0e875e02487b61dcc520b295feb6477b859065 (patch)
tree234845d306bf04446b9839c51b06d18d5f9dc9a6 /scripts/randomtest.loop
parent572b9a3019caf0929a41a45e1f3a8c7e59ec141c (diff)
downloadbusybox-w32-ff0e875e02487b61dcc520b295feb6477b859065.tar.gz
busybox-w32-ff0e875e02487b61dcc520b295feb6477b859065.tar.bz2
busybox-w32-ff0e875e02487b61dcc520b295feb6477b859065.zip
work on adding testsuite runs to randomconfig test builds
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'scripts/randomtest.loop')
-rwxr-xr-xscripts/randomtest.loop36
1 files changed, 32 insertions, 4 deletions
diff --git a/scripts/randomtest.loop b/scripts/randomtest.loop
index 28edb6732..311536df8 100755
--- a/scripts/randomtest.loop
+++ b/scripts/randomtest.loop
@@ -1,10 +1,38 @@
1#!/bin/sh 1#!/bin/sh
2 2
3test -d "$1" || { echo "'$1' is not a directory"; exit 1; }
4test -x "$1/scripts/randomtest" || { echo "No scripts/randomtest in '$1'"; exit 1; }
5
6export LIBC="uclibc"
7export CROSS_COMPILER_PREFIX="i486-linux-uclibc-"
8export MAKEOPTS="-j9"
9
3cnt=0 10cnt=0
4fail=0 11fail=0
5
6while sleep 1; do 12while sleep 1; do
7 echo "Passes: $cnt Failures: $fail" 13 echo "Passes: $cnt Failures: $fail"
8 ./randomtest >/dev/null || exit #let fail++ 14 dir="test.$$"
9 let cnt++ 15 while test -e "$dir" -o -e "failed.$dir"; do
16 dir="test.$$.$RANDOM"
17 done
18 echo "Running randconfig test in $dir..."
19 if ! "$1/scripts/randomtest" "$1" "$dir" >/dev/null; then
20 mv -- "$dir" "failed.$dir"
21 echo "Failed build in: failed.$dir"
22 exit 1 # you may comment this out...
23 let fail++
24 else
25 (
26 cd -- "$dir/testsuite" || exit 1
27 echo "Running testsuite in $dir..."
28 SKIP_KNOWN_BUGS=1 SKIP_INTERNET_TESTS=1 ./runtest -v >runtest.log 2>&1
29 )
30 if test $? != 0; then
31 echo "Failed runtest in $dir"
32 exit 1
33 fi
34 tail -n10 -- "$dir/testsuite/runtest.log"
35 rm -rf -- "$dir"
36 fi
37 let cnt++
10done 38done