summaryrefslogtreecommitdiff
path: root/test/git/test_refs.py
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2009-11-26 15:41:18 +0100
committerSebastian Thiel <byronimo@gmail.com>2009-11-26 16:52:06 +0100
commitfa98250e1dd7f296b36e0e541d3777a3256d676c (patch)
tree8bdeaacd239326e77f8c9f87c86c264a4215140c /test/git/test_refs.py
parent0d638bf6e55bc64c230999c9e42ed1b02505d0ce (diff)
downloadgitpython-fa98250e1dd7f296b36e0e541d3777a3256d676c.tar.gz
SymbolicReference is now the base for all references, allowing them to appear litereally anywhere. A 'default' reference is nothing more than a detached symbolic reference.
Added method iterate the packed refs file
Diffstat (limited to 'test/git/test_refs.py')
-rw-r--r--test/git/test_refs.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/test/git/test_refs.py b/test/git/test_refs.py
index 1eceb162..606346cf 100644
--- a/test/git/test_refs.py
+++ b/test/git/test_refs.py
@@ -64,7 +64,7 @@ class TestRefs(TestBase):
types_found = set()
for ref in self.rorepo.refs:
types_found.add(type(ref))
- assert len(types_found) == 4
+ assert len(types_found) == 3
@with_rw_repo('0.1.6')
def test_head_reset(self, rw_repo):
@@ -192,7 +192,7 @@ class TestRefs(TestBase):
# setting a non-commit as commit fails, but succeeds as object
head_tree = head.commit.tree
- self.failUnlessRaises(GitCommandError, setattr, head, 'commit', head_tree)
+ self.failUnlessRaises(ValueError, setattr, head, 'commit', head_tree)
assert head.commit == old_commit # and the ref did not change
self.failUnlessRaises(GitCommandError, setattr, head, 'object', head_tree)
@@ -255,9 +255,3 @@ class TestRefs(TestBase):
assert active_branch in heads
assert rw_repo.tags
- # NOTE: It appears git-cat-file cannot resolve refs which are packed !
- # At least it fails here for some reason
- # Couldn't reproduce the bug in a simple example though ... lets see.
- self.failUnlessRaises(ValueError, getattr, new_head, 'commit')
- self.failUnlessRaises(ValueError, getattr, symref, "commit")
-