t/t5800: skip if python version is older than 2.5
This test script depends on the git-remote-testgit python script. This python script makes use of the hashlib module which was released in python version 2.5. So, add a new pre-requisite named PYTHON_2_5_OR_NEWER to test-lib.sh and check for it in t5800. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Brandon Casey committed
Jun 1, 2010 at 19:13 UTC
2bf1033478a65c1067e1a7922a91406c797852ed
1 file changed
+8
-2
t/t5800-remote-helpers.sh
+8
-2
@@ -7,9 +7,15 @@ test_description='Test remote-helper import and export commands'
7
8
. ./test-lib.sh
9
10
-if ! test_have_prereq PYTHON
10
+if test_have_prereq PYTHON && "$PYTHON_PATH" -c '
11
+import sys
12
+if sys.hexversion < 0x02050000:
13
+ sys.exit(1)
14
+'
15
then
12
- say 'skipping git remote-testgit tests: requires Python support'
16
+ :
17
+else
18
+ say 'skipping git remote-testgit tests: requires Python 2.5 or newer'
19
test_done
20
fi
21