diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2009-10-22 11:04:30 +0200 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2009-10-22 11:04:30 +0200 |
commit | 33fa178eeb7bf519f5fff118ebc8e27e76098363 (patch) | |
tree | ab4e5789aa334688d71504d532312fb4ce572b71 /test/git/test_base.py | |
parent | 3c9f55dd8e6697ab2f9eaf384315abd4cbefad38 (diff) | |
download | gitpython-33fa178eeb7bf519f5fff118ebc8e27e76098363.tar.gz |
added Object.data_stream property allowing to stream object data directly.Considering the implementation of the git commnd which temporarily keeps it in a cache, it doesnt make a huge diffence as the data is kept in memory while streaming. Only good thing is that it is in a different process so python will never see it if done properly
Diffstat (limited to 'test/git/test_base.py')
-rw-r--r-- | test/git/test_base.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/git/test_base.py b/test/git/test_base.py index 71576048..4ad98d7f 100644 --- a/test/git/test_base.py +++ b/test/git/test_base.py @@ -48,6 +48,11 @@ class TestBase(object): assert not item.path.startswith("/") # must be relative assert isinstance(item.mode, int) # END index object check + + # read from stream + data_stream = item.data_stream + data = data_stream.read() + assert data # END for each object type to create # each has a unique sha |