CDPATH test

This commit is contained in:
Thomas Levine 2016-02-28 22:03:11 +00:00
parent cb91efb126
commit c93456f6e5
5 changed files with 7 additions and 8 deletions

View File

@ -1,6 +0,0 @@
#!/bin/sh
cd ..
export CDPATH=$PWD
./urchin -f 'tests/urchin exit code' >/dev/null

View File

@ -1,6 +1,8 @@
#!/bin/sh
set -e
export tmp=$(mktemp -d)
contents="$1"
expectation="$2"
@ -20,4 +22,8 @@ case "$expectation" in ok) regex='^ok 1 - testcase';;
esac
# Run the test suite
set +e
../../urchin -n -t $testdir | grep "$regex"
code=$?
rm -R $tmp
exit $?

View File

@ -0,0 +1 @@
CDPATH=/ .test_testsuite '' ok

View File

@ -1,2 +1 @@
export tmp=$(mktemp -d)
export PATH="$PWD:$PATH"

View File

@ -1 +0,0 @@
rm -R "$tmp"