From 5cc7c456a7325c09088223f52011c72e5c4199dc Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 23 Jul 2015 14:36:18 +1000 Subject: [PATCH] autotest: fixed sense of test for autotest directory fixes PR#2593 --- Tools/autotest/sim_vehicle.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Tools/autotest/sim_vehicle.sh b/Tools/autotest/sim_vehicle.sh index 275d4d92e5..01e817043b 100755 --- a/Tools/autotest/sim_vehicle.sh +++ b/Tools/autotest/sim_vehicle.sh @@ -282,7 +282,9 @@ if [ -n "$OVERRIDE_BUILD_TARGET" ]; then fi autotest="../Tools/autotest" -[ -d "$autotest" ] && { +[ -d "$autotest" ] || { + # we are not running from one of the standard vehicle directories. Use + # the location of the sim_vehicle.sh script to find the path autotest=$(dirname $(readlink -e $0)) } pushd $autotest/../../$VEHICLE || {