diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2011-05-30 21:14:22 +0200 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2011-05-30 21:23:17 +0200 |
commit | 6f960586feccff8c1f2c717765eb0a5e8b9cd6f3 (patch) | |
tree | a1c9e6eca585cd7db760ddbd23aacadde6d8d1d4 /git/test/test_refs.py | |
parent | 7fab60c596cdd2588f9c7b2b4eb9f93f8736b915 (diff) | |
download | gitpython-6f960586feccff8c1f2c717765eb0a5e8b9cd6f3.tar.gz |
Fixed remaining tests as good as possible. remote/fetch/pull and submodule tests need some more work. Also, the tests need to be reorganized and move closer to their actual location within gitpython. Hence the refs tests go to git.test.refs, etc
Diffstat (limited to 'git/test/test_refs.py')
-rw-r--r-- | git/test/test_refs.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/git/test/test_refs.py b/git/test/test_refs.py index 2e018e7f..3e6c0b3a 100644 --- a/git/test/test_refs.py +++ b/git/test/test_refs.py @@ -4,13 +4,15 @@ # This module is part of GitPython and is released under # the BSD License: http://www.opensource.org/licenses/bsd-license.php -from git.test.lib import TestBase -from git.ref import * -import git.ref as ref +from git.test.lib import TestBase, with_rw_repo +from git.refs import * +import git.refs as ref from git.util import Actor from git.objects.tag import TagObject +from git.exc import GitCommandError + from itertools import chain import os @@ -51,7 +53,7 @@ class TestRefs(TestBase): # END if we have a tag object # END for tag in repo-tags assert tag_object_refs - assert isinstance(TagReference.list_items(self.rorepo)['0.5.0'], TagReference) + assert isinstance(TagReference.list_items(self.rorepo)['0.1.6'], TagReference) def test_tags(self): # tag refs can point to tag objects or to commits @@ -69,7 +71,7 @@ class TestRefs(TestBase): assert len(s) == ref_count assert len(s|s) == ref_count - @with_rw_repo + @with_rw_repo("0.1.6") def test_heads(self, rw_repo): for head in Head.iter_items(rw_repo): assert head.name @@ -155,7 +157,7 @@ class TestRefs(TestBase): def test_orig_head(self): assert type(HEAD(self.rorepo).orig_head()) == SymbolicReference - @with_rw_repo + @with_rw_repo("0.1.6") def test_head_reset(self, rw_repo): cur_head = HEAD(rw_repo) old_head_commit = cur_head.commit |