From 0425bc64384fe9a6a22edb7831d6e8c1756e2c7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steve=20Fr=C3=A9cinaux?= Date: Sat, 6 Sep 2008 00:10:12 +0200 Subject: Implement dict protocol for trees. It is rather intuitive to consider trees as a dict of objects (like a directory could be seen as a dict of files). --- test/git/test_repo.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test/git/test_repo.py') diff --git a/test/git/test_repo.py b/test/git/test_repo.py index c7a4c01b..3c323878 100644 --- a/test/git/test_repo.py +++ b/test/git/test_repo.py @@ -96,8 +96,8 @@ class TestRepo(object): tree = self.repo.tree('master') - assert_equal(4, len([c for c in tree.contents.values() if isinstance(c, Blob)])) - assert_equal(3, len([c for c in tree.contents.values() if isinstance(c, Tree)])) + assert_equal(4, len([c for c in tree.values() if isinstance(c, Blob)])) + assert_equal(3, len([c for c in tree.values() if isinstance(c, Tree)])) assert_true(git.called) assert_equal(git.call_args, (('ls_tree', 'master'), {})) -- cgit v1.2.1