summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-09-25 17:40:24 (GMT)
committerJunio C Hamano <gitster@pobox.com>2012-09-25 17:40:24 (GMT)
commit86bdfa395559b8d99fbec9b8366524aaa311399b (patch)
tree26b94060d8e1e79019a304dfe956f0ca61c3ebed /t
parentcbea001a8694cdc365fec14f8ad5718feddc3697 (diff)
parent2006f0adaee036145b4261b942d944adb18647ed (diff)
downloadgit-86bdfa395559b8d99fbec9b8366524aaa311399b.zip
git-86bdfa395559b8d99fbec9b8366524aaa311399b.tar.gz
git-86bdfa395559b8d99fbec9b8366524aaa311399b.tar.bz2
Merge branch 'rr/test-make-sure-we-have-git'
Only the first test t0000 in the test suite made sure we have built Git to be tested; move the check to test-lib so that it applies to all tests equally. * rr/test-make-sure-we-have-git: t/test-lib: make sure Git has already been built
Diffstat (limited to 't')
-rwxr-xr-xt/t0000-basic.sh10
-rw-r--r--t/test-lib.sh9
2 files changed, 9 insertions, 10 deletions
diff --git a/t/t0000-basic.sh b/t/t0000-basic.sh
index ae6a3f0..08677df 100755
--- a/t/t0000-basic.sh
+++ b/t/t0000-basic.sh
@@ -18,16 +18,6 @@ swapping compression and hashing order, the person who is making the
modification *should* take notice and update the test vectors here.
'
-################################################################
-# It appears that people try to run tests without building...
-
-../git >/dev/null
-if test $? != 1
-then
- echo >&2 'You do not seem to have built git yet.'
- exit 1
-fi
-
. ./test-lib.sh
################################################################
diff --git a/t/test-lib.sh b/t/test-lib.sh
index aad4606..bff3d75 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