summaryrefslogtreecommitdiff
path: root/tests/qemu-iotests/check
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2013-09-04 13:16:04 +0200
committerStefan Hajnoczi <stefanha@redhat.com>2013-09-06 15:25:09 +0200
commit79e40ab10e1f4450c11ab8430cb2547146ded639 (patch)
tree183a26632051ce107ae7708e8480654acd0845d0 /tests/qemu-iotests/check
parent8caf907f07688972e5e7cd11526079b1665d6dba (diff)
downloadqemu-79e40ab10e1f4450c11ab8430cb2547146ded639.tar.gz
qemu-iotests: Whitespace cleanup
These scripts used to have a four characters indentation, with eight consecutive spaces converted into a tab. Convert everything into spaces. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/check')
-rwxr-xr-xtests/qemu-iotests/check234
1 files changed, 117 insertions, 117 deletions
diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check
index 74628ae637..e51bae8cee 100755
--- a/tests/qemu-iotests/check
+++ b/tests/qemu-iotests/check
@@ -78,50 +78,50 @@ _wrapup()
if $showme
then
- :
+ :
elif $needwrap
then
- if [ -f check.time -a -f $tmp.time ]
- then
- cat check.time $tmp.time \
- | $AWK_PROG '
- { t[$1] = $2 }
-END { if (NR > 0) {
- for (i in t) print i " " t[i]
- }
- }' \
- | sort -n >$tmp.out
- mv $tmp.out check.time
- fi
-
- if [ -f $tmp.expunged ]
- then
- notrun=`wc -l <$tmp.expunged | sed -e 's/ *//g'`
- try=`expr $try - $notrun`
- list=`echo "$list" | sed -f $tmp.expunged`
- fi
-
- echo "" >>check.log
- date >>check.log
- echo $list | fmt | sed -e 's/^/ /' >>check.log
- $interrupt && echo "Interrupted!" >>check.log
-
- if [ ! -z "$notrun" ]
- then
- echo "Not run:$notrun"
- echo "Not run:$notrun" >>check.log
- fi
+ if [ -f check.time -a -f $tmp.time ]
+ then
+ cat check.time $tmp.time \
+ | $AWK_PROG '
+ { t[$1] = $2 }
+END { if (NR > 0) {
+ for (i in t) print i " " t[i]
+ }
+ }' \
+ | sort -n >$tmp.out
+ mv $tmp.out check.time
+ fi
+
+ if [ -f $tmp.expunged ]
+ then
+ notrun=`wc -l <$tmp.expunged | sed -e 's/ *//g'`
+ try=`expr $try - $notrun`
+ list=`echo "$list" | sed -f $tmp.expunged`
+ fi
+
+ echo "" >>check.log
+ date >>check.log
+ echo $list | fmt | sed -e 's/^/ /' >>check.log
+ $interrupt && echo "Interrupted!" >>check.log
+
+ if [ ! -z "$notrun" ]
+ then
+ echo "Not run:$notrun"
+ echo "Not run:$notrun" >>check.log
+ fi
if [ ! -z "$n_bad" -a $n_bad != 0 ]
- then
- echo "Failures:$bad"
- echo "Failed $n_bad of $try tests"
- echo "Failures:$bad" | fmt >>check.log
- echo "Failed $n_bad of $try tests" >>check.log
- else
- echo "Passed all $try tests"
- echo "Passed all $try tests" >>check.log
- fi
- needwrap=false
+ then
+ echo "Failures:$bad"
+ echo "Failed $n_bad of $try tests"
+ echo "Failures:$bad" | fmt >>check.log
+ echo "Failed $n_bad of $try tests" >>check.log
+ else
+ echo "Passed all $try tests"
+ echo "Passed all $try tests" >>check.log
+ fi
+ needwrap=false
fi
rm -f /tmp/*.out /tmp/*.err /tmp/*.time
@@ -185,82 +185,82 @@ do
if $showme
then
- echo
- continue
- elif [ -f expunged ] && $expunge && egrep "^$seq([ ]|\$)" expunged >/dev/null
+ echo
+ continue
+ elif [ -f expunged ] && $expunge && egrep "^$seq([ ]|\$)" expunged >/dev/null
then
- echo " - expunged"
- rm -f $seq.out.bad
- echo "/^$seq\$/d" >>$tmp.expunged
+ echo " - expunged"
+ rm -f $seq.out.bad
+ echo "/^$seq\$/d" >>$tmp.expunged
elif [ ! -f $seq ]
then
- echo " - no such test?"
- echo "/^$seq\$/d" >>$tmp.expunged
+ echo " - no such test?"
+ echo "/^$seq\$/d" >>$tmp.expunged
else
- # really going to try and run this one
- #
- rm -f $seq.out.bad
- lasttime=`sed -n -e "/^$seq /s/.* //p" <check.time`
- if [ "X$lasttime" != X ]; then
- echo -n " ${lasttime}s ..."
- else
- echo -n " " # prettier output with timestamps.
- fi
- rm -f core $seq.notrun
-
- # for hangcheck ...
- echo "$seq" >/tmp/check.sts
-
- start=`_wallclock`
- $timestamp && echo -n " ["`date "+%T"`"]"
- [ ! -x $seq ] && chmod u+x $seq # ensure we can run it
- MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(($RANDOM % 255 + 1))} \
- ./$seq >$tmp.out 2>&1
- sts=$?
- $timestamp && _timestamp
- stop=`_wallclock`
-
- if [ -f core ]
- then
- echo -n " [dumped core]"
- mv core $seq.core
- err=true
- fi
-
- if [ -f $seq.notrun ]
- then
- $timestamp || echo -n " [not run] "
- $timestamp && echo " [not run]" && echo -n " $seq -- "
- cat $seq.notrun
- notrun="$notrun $seq"
- else
- if [ $sts -ne 0 ]
- then
- echo -n " [failed, exit status $sts]"
- err=true
- fi
- if [ ! -f $seq.out ]
- then
- echo " - no qualified output"
- err=true
- else
- if diff -w $seq.out $tmp.out >/dev/null 2>&1
- then
- echo ""
- if $err
- then
- :
- else
- echo "$seq `expr $stop - $start`" >>$tmp.time
- fi
- else
- echo " - output mismatch (see $seq.out.bad)"
- mv $tmp.out $seq.out.bad
- $diff -w $seq.out $seq.out.bad
- err=true
- fi
- fi
- fi
+ # really going to try and run this one
+ #
+ rm -f $seq.out.bad
+ lasttime=`sed -n -e "/^$seq /s/.* //p" <check.time`
+ if [ "X$lasttime" != X ]; then
+ echo -n " ${lasttime}s ..."
+ else
+ echo -n " " # prettier output with timestamps.
+ fi
+ rm -f core $seq.notrun
+
+ # for hangcheck ...
+ echo "$seq" >/tmp/check.sts
+
+ start=`_wallclock`
+ $timestamp && echo -n " ["`date "+%T"`"]"
+ [ ! -x $seq ] && chmod u+x $seq # ensure we can run it
+ MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(($RANDOM % 255 + 1))} \
+ ./$seq >$tmp.out 2>&1
+ sts=$?
+ $timestamp && _timestamp
+ stop=`_wallclock`
+
+ if [ -f core ]
+ then
+ echo -n " [dumped core]"
+ mv core $seq.core
+ err=true
+ fi
+
+ if [ -f $seq.notrun ]
+ then
+ $timestamp || echo -n " [not run] "
+ $timestamp && echo " [not run]" && echo -n " $seq -- "
+ cat $seq.notrun
+ notrun="$notrun $seq"
+ else
+ if [ $sts -ne 0 ]
+ then
+ echo -n " [failed, exit status $sts]"
+ err=true
+ fi
+ if [ ! -f $seq.out ]
+ then
+ echo " - no qualified output"
+ err=true
+ else
+ if diff -w $seq.out $tmp.out >/dev/null 2>&1
+ then
+ echo ""
+ if $err
+ then
+ :
+ else
+ echo "$seq `expr $stop - $start`" >>$tmp.time
+ fi
+ else
+ echo " - output mismatch (see $seq.out.bad)"
+ mv $tmp.out $seq.out.bad
+ $diff -w $seq.out $seq.out.bad
+ err=true
+ fi
+ fi
+ fi
fi
@@ -268,12 +268,12 @@ do
#
if $err
then
- bad="$bad $seq"
- n_bad=`expr $n_bad + 1`
- quick=false
+ bad="$bad $seq"
+ n_bad=`expr $n_bad + 1`
+ quick=false
fi
[ -f $seq.notrun ] || try=`expr $try + 1`
-
+
seq="after_$seq"
done