summaryrefslogtreecommitdiff
path: root/test/git/test_repo.py
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2009-10-23 00:14:24 +0200
committerSebastian Thiel <byronimo@gmail.com>2009-10-23 00:14:24 +0200
commit00499d994fea6fb55a33c788f069782f917dbdd4 (patch)
treef3de7739d34003a7356bd72769f212a47ebc8993 /test/git/test_repo.py
parentb2a14e4b96a0ffc5353733b50266b477539ef899 (diff)
parentd1bd99c0a376dec63f0f050aeb0c40664260da16 (diff)
downloadgitpython-00499d994fea6fb55a33c788f069782f917dbdd4.tar.gz
Merge branch 'symbolic_ref' into improvements
* symbolic_ref: SymbolicReferences can now change they references safely as I think and well controlled, including test. Adjusted tests to deal with API changes Added SymbolicReference and HEAD type to better represent these special types of references and allow special handling
Diffstat (limited to 'test/git/test_repo.py')
-rw-r--r--test/git/test_repo.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/test/git/test_repo.py b/test/git/test_repo.py
index 02eea7de..b02610f4 100644
--- a/test/git/test_repo.py
+++ b/test/git/test_repo.py
@@ -168,17 +168,11 @@ class TestRepo(TestBase):
self.rorepo._bare = True
assert self.rorepo.is_dirty == False
- @patch_object(Git, '_call_process')
- def test_active_branch(self, git):
- git.return_value = 'refs/heads/major-refactoring'
- assert_equal(self.rorepo.active_branch.name, 'major-refactoring')
- assert_equal(git.call_args, (('symbolic_ref', 'HEAD'), {}))
-
def test_head(self):
- assert self.rorepo.head.object == self.rorepo.active_branch.object
+ assert self.rorepo.head.reference.object == self.rorepo.active_branch.object
def test_tag(self):
- assert self.rorepo.tag('0.1.5').commit
+ assert self.rorepo.tag('refs/tags/0.1.5').commit
def test_archive(self):
tmpfile = os.tmpfile()