Thomas Vachuska

Changing stc scenarios to be compatible with multiple links in the ATT MPLS test topology.

Change-Id: I9ee8fd9a3279a0d59f837569a7ada0eb77fd1d41
......@@ -6,6 +6,8 @@
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
. $ONOS_ROOT/tools/build/envDefaults
export MAX_WAIT=45
cmd="$1" && shift
log="screenlog.0"
remote="$ONOS_USER@$OCN"
......@@ -25,8 +27,9 @@ sendAndExpect)
wait)
ssh $remote "
sleep 1 && while test ! -f $log; do sleep 1; done
while ! (tail -n1 $log | egrep -q '^mininet>'); do sleep 1; done
let count=0
sleep 1 && while test ! -f $log; do if test \$count -ge $MAX_WAIT; then exit 1; fi; sleep 1; let count=count+1; done
while ! (tail -n1 $log | egrep -q '^mininet>'); do if [ \$count -ge $MAX_WAIT ]; then exit 1; fi; sleep 1; done
sleep ${1-:1}
"
;;
......@@ -36,7 +39,8 @@ expect)
ssh $remote "
sleep 1
if [ ! -f $log ]; then exit 1; fi;
while ! (tail -n1 $log | egrep -q '^mininet>'); do sleep 1; done
let count=0
while ! (tail -n1 $log | egrep -q '^mininet>'); do if test \$count -ge $MAX_WAIT; then exit 1; fi; sleep 1; let count=count+1; done
tac $log | awk '{ print \$0; } /^mininet>/ { if (on) { exit 0; } on=1; }' | tac > $aux
cat $aux
set -x
......
......@@ -20,7 +20,7 @@
exec="onos-mininet sendAndExpect py net.pingAll(1) --expect Results: .* dropped"/>
<step name="Check-Summary-For-Hosts" requires="~Ping-All-And-Verify"
exec="onos-check-summary ${OC1} [0-9]* 25 112 25"/>
exec="onos-check-summary ${OC1} [0-9]* 25 140 25"/>
<step name="Config-Topo" requires="Check-Summary-For-Hosts"
exec="onos-topo-cfg ${OC1} ${ONOS_ROOT}/tools/test/topos/attmpls.json"/>
......
......@@ -37,7 +37,7 @@
exec="onos-mininet wait 15"/>
<step name="Check-Summary" requires="Wait-For-Mininet"
exec="onos-check-summary ${OC1} [0-9]* 25 112 0"/>
exec="onos-check-summary ${OC1} [0-9]* 25 140 0"/>
<step name="Balance-Masters" requires="Check-Summary"
exec="onos ${OC1} balance-masters"/>
......