run-spec will now set wd to spec dir

This removes sourcing complications
env
Mike Gerwitz 2014-06-09 22:39:30 -04:00
parent 6a5c0b3d0d
commit 58a3f75d05
No known key found for this signature in database
GPG Key ID: F22BB8158EE30EAB
2 changed files with 4 additions and 2 deletions

View File

@ -24,6 +24,8 @@ source spec
declare -r tcase="${1?Missing test case path}" declare -r tcase="${1?Missing test case path}"
_begin-spec _begin-spec
source "$tcase" || exit $? cd "$( dirname "$tcase" )" \
&& source "$tcase" \
|| exit $?
_end-spec _end-spec

View File

@ -34,7 +34,7 @@
# This will take an arbitrary script from stdin and execute it # This will take an arbitrary script from stdin and execute it
test-run() test-run()
{ {
../src/run-spec <( cat ) ( cd ../src && ./run-spec <( cat ) )
} }