diff options
author | Ramkumar Ramachandra <artagnon@gmail.com> | 2012-09-17 19:06:19 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2012-09-18 23:22:19 +0200 |
commit | 2006f0adaee036145b4261b942d944adb18647ed (patch) | |
tree | 86a5c3e10a544551a92736a40aa06dcc84022041 /t/test-lib.sh | |
parent | t/perf: add "trash directory" to .gitignore (diff) | |
download | git-2006f0adaee036145b4261b942d944adb18647ed.tar.xz git-2006f0adaee036145b4261b942d944adb18647ed.zip |
t/test-lib: make sure Git has already been built
When tests were run without building git, they stopped with:
.: 54: Can't open /path/to/git/source/t/../GIT-BUILD-OPTIONS
Move the check that makes sure that git has already been built from
t0000 to test-lib, so that any test will do so before it runs.
Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to '')
-rw-r--r-- | t/test-lib.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/t/test-lib.sh b/t/test-lib.sh index 78c428619e..e823d86e41 100644 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -51,6 +51,15 @@ then fi GIT_BUILD_DIR="$TEST_DIRECTORY"/.. +################################################################ +# It appears that people try to run tests without building... +"$GIT_BUILD_DIR/git" >/dev/null +if test $? != 1 +then + echo >&2 'error: you do not seem to have built git yet.' + exit 1 +fi + . "$GIT_BUILD_DIR"/GIT-BUILD-OPTIONS export PERL_PATH SHELL_PATH |