2016-11-25 17:18:40 +01:00
|
|
|
#!/cmd/rc
|
|
|
|
|
|
|
|
rfork
|
|
|
|
|
2017-09-11 01:01:11 +02:00
|
|
|
if( ! test -d /dev/posix ){
|
|
|
|
sys/posixly -d /tmp/qa-posixly.log -p $PID &
|
|
|
|
# sys/ctrace -o /tmp/posixly.trace $APID &
|
|
|
|
}
|
|
|
|
|
2016-11-25 17:18:40 +01:00
|
|
|
dir=$1
|
|
|
|
if(~ $dir '') dir=/qa
|
|
|
|
|
|
|
|
|
2017-10-22 13:22:37 +02:00
|
|
|
l = `{du -a /arch/$OBJTYPE/$dir|awk '{print $2}'|sort}
|
2016-11-25 17:18:40 +01:00
|
|
|
|
|
|
|
failed = ()
|
2017-04-28 00:47:12 +02:00
|
|
|
runner=.runner
|
2016-11-25 17:18:40 +01:00
|
|
|
|
|
|
|
for(t in $l){
|
|
|
|
if(test -x $t) {
|
2017-04-28 00:47:12 +02:00
|
|
|
if( test -x $t$runner ) { }
|
|
|
|
if not {
|
|
|
|
echo -n $t:
|
|
|
|
$t > /tmp/qa.log >[2=1]
|
2017-10-22 13:22:37 +02:00
|
|
|
st = $STATUS
|
2017-08-31 00:29:52 +02:00
|
|
|
switch( `{echo $st|field 3} ){
|
|
|
|
case PASS
|
2017-04-28 00:47:12 +02:00
|
|
|
rm /tmp/qa.log && echo PASS
|
2017-08-31 00:29:52 +02:00
|
|
|
case SKIP
|
|
|
|
echo -n ' SKIP: ' && cat /tmp/qa.log && rm /tmp/qa.log
|
|
|
|
case FAIL
|
|
|
|
echo $st && cat /tmp/qa.log; exit $st
|
|
|
|
case *
|
|
|
|
echo Unexpected test result: $st && cat /tmp/qa.log; exit $st
|
2017-04-28 00:47:12 +02:00
|
|
|
}
|
2017-04-24 00:06:33 +02:00
|
|
|
}
|
2016-11-25 17:18:40 +01:00
|
|
|
}
|
|
|
|
}
|