diff --git a/scripts/unittest b/scripts/unittest index fe0625b092..9baf52058a 100755 --- a/scripts/unittest +++ b/scripts/unittest @@ -34,13 +34,13 @@ fi declare -a EXTRA_ARGS if [ -z "${ARANGOSH}" ]; then - if [ -x build/bin/arangosh ]; then + if [ -x build/bin/arangosh -a ! -d build/bin/arangosh ]; then ARANGOSH="build/bin/arangosh${EXT}" - elif [ -x bin/arangosh ]; then + elif [ -x bin/arangosh -a ! -d bin/arangosh ]; then ARANGOSH="bin/arangosh${EXT}" - elif [ -x arangosh ]; then + elif [ -x arangosh -a ! -d arangosh ]; then ARANGOSH="arangosh${EXT}" - elif [ -x usr/bin/arangosh ]; then + elif [ -x usr/bin/arangosh -a ! -d usr/bin/arangosh ]; then ARANGOSH="usr/bin/arangosh${EXT}" else ARANGOSH="$(find "${EXEC_PATH}" -name "arangosh${EXT}" -perm -001 -type f | head -n 1)"