summaryrefslogtreecommitdiff
path: root/check
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-02-06 20:40:36 +0000
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-02-06 21:13:39 +0000
commit626bf72a572d8852e069c75553c5d121a29bf587 (patch)
tree0f1d72e42374853b5cbcbc9bb8105d2de4945d00 /check
parentf11cc83adff3c88294bef0fa143eb317b2e9e02f (diff)
downloadmorph-626bf72a572d8852e069c75553c5d121a29bf587.tar.gz
Set PYTHONPATH during tests
This is necessary so that the write extension run by cmdtest finds the morphlib of the source tree we're running ./check in, rather than the system installed one.
Diffstat (limited to 'check')
-rwxr-xr-xcheck6
1 files changed, 6 insertions, 0 deletions
diff --git a/check b/check
index 67b4ce34..baced129 100755
--- a/check
+++ b/check
@@ -19,6 +19,12 @@
set -e
+case "$PYTHONPATH" in
+ '') PYTHONPATH="$(pwd)" ;;
+ *) PYTHONPATH="$(pwd):$PYTHONPATH" ;;
+esac
+export PYTHONPATH
+
python setup.py clean check
cmdtest tests
cmdtest tests.branching