tests: Fix browser.sh path detection to be less STI specific
Only set `$SOURCE` to ./source/ if that actually exists, which is when it is being called through Standard Test Interface. Provide fallbacks for using FMF or when calling the script manually.
This commit is contained in:
parent
168e0397aa
commit
a0f5493eef
@ -1,10 +1,14 @@
|
||||
#!/bin/sh
|
||||
set -eux
|
||||
|
||||
# from standard-test-source
|
||||
TESTS="$(realpath $(dirname "$0"))"
|
||||
if [ -d source ]; then
|
||||
# path for standard-test-source
|
||||
SOURCE="$(pwd)/source"
|
||||
else
|
||||
SOURCE="$(realpath $TESTS/..)"
|
||||
fi
|
||||
LOGS="$(pwd)/logs"
|
||||
TESTS="$(pwd)/tests"
|
||||
mkdir -p "$LOGS"
|
||||
chmod a+w "$LOGS"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user