summaryrefslogtreecommitdiff
path: root/test/git/test_tree.py
diff options
context:
space:
mode:
authorSteve Frécinaux <code@istique.net>2008-09-05 21:51:14 +0200
committerSteve Frécinaux <code@istique.net>2008-09-05 22:47:37 +0200
commitb377c07200392ac35a6ed668673451d3c9b1f5c7 (patch)
tree59d864deb2049863dc4d989927c360851ca4c280 /test/git/test_tree.py
parent590638f9a56440a2c41cc04f52272ede04c06a43 (diff)
downloadgitpython-b377c07200392ac35a6ed668673451d3c9b1f5c7.tar.gz
Use a dictionnary for tree contents
It seems more natural to use a dictionnary for directories, since we usually want to access them by name, and entry order is not relevant. Also, finding a particular blob given its name is O(1) instead of O(N).
Diffstat (limited to 'test/git/test_tree.py')
-rw-r--r--test/git/test_tree.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/git/test_tree.py b/test/git/test_tree.py
index 957b8962..d66764b3 100644
--- a/test/git/test_tree.py
+++ b/test/git/test_tree.py
@@ -18,7 +18,7 @@ class TestTree(object):
tree = self.repo.tree('master')
- child = tree.contents[-1]
+ child = tree.contents['grit']
child.contents
child.contents