1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/bin/bash
runname=$1
pass=1
alldone=1
while ! $alldone;do
sleep 5
bigrun_running=$(megatest -list-runs a|egrep 'bigrun\(.*RUNNING'|wc -l)
bigrun2_pass=$(megatest -list-runs a|egrep 'bigrun2.*COMPLETED.*PASS')
if [[ $bigrun_running -gt 0 && $bigrun2_pass -gt 0 ]];then
pass=0
alldone=0
fi
done
if $pass;then
echo PASS
exit 0
else
echo FAIL
exit 1
fi
|
|
|
|
>
|
|
>
|
|
|
>
>
>
>
|
|
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
|
#!/bin/bash
runname=$1
pass=no
alldone=no
while [[ $alldone == no ]];do
sleep 5
$MTRUNNER $MTTESTDIR/fdktestqa/testqa $MTPATH megatest -list-runs $runname > list-runs.log
bigrun_running=$(cat list-runs.log | egrep 'bigrun\(.*RUNNING'|wc -l)
bigrun2_pass=$(cat list-runs.log | egrep 'bigrun2.*COMPLETED.*PASS'|wc -l)
echo "bigrun_running=$bigrun_running, bigrun2_pass=$bigrun2_pass"
if [[ $bigrun_running -gt 0 ]] && [[ $bigrun2_pass -gt 0 ]];then
pass=yes
alldone=yes
fi
if [[ $bigrun_running -eq 0 ]];then
echo "bigrun all done and no bigrun2 found with PASS."
alldone=yes
fi
done
if [[ $pass == yes ]];then
echo PASS
exit 0
else
echo FAIL
exit 1
fi
|