OSDN Git Service

tests: move test_lazy_prereq JGIT to test-lib.sh
authorJonathan Tan <jonathantanmy@google.com>
Fri, 9 Sep 2016 17:36:28 +0000 (10:36 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 9 Sep 2016 20:37:52 +0000 (13:37 -0700)
This enables JGIT to be used as a prereq in invocations of
test_expect_success (and other functions) in other test scripts.

Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5310-pack-bitmaps.sh
t/test-lib.sh

index 3893afd..1e376ea 100755 (executable)
@@ -158,10 +158,6 @@ test_expect_success 'pack with missing parent' '
        git pack-objects --stdout --revs <revs >/dev/null
 '
 
-test_lazy_prereq JGIT '
-       type jgit
-'
-
 test_expect_success JGIT 'we can read jgit bitmaps' '
        git clone . compat-jgit &&
        (
index d731d66..c9c1037 100644 (file)
@@ -1072,6 +1072,10 @@ test_lazy_prereq NOT_ROOT '
        test "$uid" != 0
 '
 
+test_lazy_prereq JGIT '
+       type jgit
+'
+
 # SANITY is about "can you correctly predict what the filesystem would
 # do by only looking at the permission bits of the files and
 # directories?"  A typical example of !SANITY is running the test