diff options
author | Manuel Buil <manuel.buil@ericsson.com> | 2016-10-11 10:30:10 +0200 |
---|---|---|
committer | Jose Lausuch <jose.lausuch@ericsson.com> | 2016-10-11 11:57:29 +0000 |
commit | 2776686019fa48e5abfc25d2799607daab0b7d08 (patch) | |
tree | 2fec93bebf6b82a9ffb84381d76682983834d74e /testcases/features | |
parent | 1664ce9a60f3764e2f5b5273e8f6d6c6716f3879 (diff) |
Bug fix in odl-sfc testcase
Test is stopping if the route to the VMs ip range is already there because
the command that adds that, exits with code 1 and set -e is activated.
Now it is checked if it is there and if not, the command is executed
Change-Id: I820a55aff2572aadcb1950fa9218b114a9058c57
Signed-off-by: Manuel Buil <manuel.buil@ericsson.com>
(cherry picked from commit e2c2ff612e7086ce2a1520029f5f58e75186ec17)
Diffstat (limited to 'testcases/features')
-rwxr-xr-x | testcases/features/sfc/compute_presetup_CI.bash | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/testcases/features/sfc/compute_presetup_CI.bash b/testcases/features/sfc/compute_presetup_CI.bash index 57d3d8278..c776c2f8c 100755 --- a/testcases/features/sfc/compute_presetup_CI.bash +++ b/testcases/features/sfc/compute_presetup_CI.bash @@ -17,5 +17,10 @@ sshpass -p r00tme scp $ssh_options correct_classifier.bash ${INSTALLER_IP}:/root sshpass -p r00tme ssh $ssh_options root@${INSTALLER_IP} 'scp correct_classifier.bash '"$ip"':/root' sshpass -p r00tme ssh $ssh_options root@${INSTALLER_IP} 'ssh root@'"$ip"' ifconfig br-int up' +output=$(sshpass -p r00tme ssh $ssh_options root@${INSTALLER_IP} 'ssh root@'"$ip"' ip route | \ +cut -d" " -f1 | grep 11.0.0.0' ; exit 0) + +if [ -z "$output" ]; then sshpass -p r00tme ssh $ssh_options root@${INSTALLER_IP} 'ssh root@'"$ip"' ip route add 11.0.0.0/24 \ dev br-int' +fi |