correction unitest chemin acces

This commit is contained in:
hugogogo
2021-12-14 23:03:59 +01:00
parent c60c647c33
commit 1f3b86f0f4

View File

@@ -84,10 +84,15 @@ DEFAULT_DIR="./tests/defaults/"
# the ! is for indirect parameter expansion # the ! is for indirect parameter expansion
# $i expand in integers 1,2,3... # $i expand in integers 1,2,3...
# $1,$2,$3... expand in arguments of process call # $1,$2,$3... expand in arguments of process call
FILE="${!i/#/$TEST_DIR}" FILE="${!i%.sh}"
FILE="${FILE%.sh}"
FILE="${FILE/%/.sh}" FILE="${FILE/%/.sh}"
if ! [ -e "$FILE" ] if ! [ -e "$FILE" ]
then
FILE="${!i/#/$TEST_DIR}"
FILE="${FILE%.sh}"
FILE="${FILE/%/.sh}"
fi
if ! [ -e "$FILE" ]
then then
FILE="${!i/#/$DEFAULT_DIR}" FILE="${!i/#/$DEFAULT_DIR}"
FILE="${FILE%.sh}" FILE="${FILE%.sh}"