aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTommi Virtanen <tv@eagain.net>2009-09-16 22:28:17 -0700
committerTommi Virtanen <tv@eagain.net>2009-09-16 22:28:17 -0700
commit4b19d45a3b482049efa2cee52d42fcccecc67926 (patch)
tree699508c49b9465882ec9704640204fd6d6563e66
parentUse "git shell" instead of "git-shell", for compatibility with git 1.6. (diff)
downloadgitosis-gentoo-4b19d45a3b482049efa2cee52d42fcccecc67926.zip
gitosis-gentoo-4b19d45a3b482049efa2cee52d42fcccecc67926.tar.gz
gitosis-gentoo-4b19d45a3b482049efa2cee52d42fcccecc67926.tar.bz2
Fix unit test failure with git >=1.6.0
-rw-r--r--gitosis/test/test_repository.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/gitosis/test/test_repository.py b/gitosis/test/test_repository.py
index 6ce4129..14c6764 100644
--- a/gitosis/test/test_repository.py
+++ b/gitosis/test/test_repository.py
@@ -63,7 +63,12 @@ def test_init_templates():
got = readFile(os.path.join(path, 'hooks', 'post-update'))
eq(got, '#!/bin/sh\n# i can override standard templates\n')
# standard templates are there, too
- assert os.path.isfile(os.path.join(path, 'hooks', 'pre-rebase'))
+ assert (
+ # compatibility with git <1.6.0
+ os.path.isfile(os.path.join(path, 'hooks', 'pre-rebase'))
+ # for git >=1.6.0
+ or os.path.isfile(os.path.join(path, 'hooks', 'pre-rebase.sample'))
+ )
def test_init_environment():
tmp = maketemp()