diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2015-01-05 10:09:51 +0100 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2015-01-05 10:09:51 +0100 |
commit | bc8c91200a7fb2140aadd283c66b5ab82f9ad61e (patch) | |
tree | 54f8b4e09ae36f465da25ecd16d6377a2a8414a8 /git/test/test_index.py | |
parent | ae2ff0f9d704dc776a1934f72a339da206a9fff4 (diff) | |
download | gitpython-py3.tar.gz |
Fixed io types to make tests work on PY2 once again.py3
Now it's about going through PY3 issues
Diffstat (limited to 'git/test/test_index.py')
-rw-r--r-- | git/test/test_index.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/git/test/test_index.py b/git/test/test_index.py index 70d70a05..38cc3563 100644 --- a/git/test/test_index.py +++ b/git/test/test_index.py @@ -31,7 +31,7 @@ from stat import ( ST_MODE ) -from io import StringIO +from io import BytesIO from gitdb.base import IStream from git.objects import Blob from git.index.typ import ( @@ -698,9 +698,9 @@ class TestIndex(TestBase): # instead of throwing the Exception we are expecting. This is # a quick hack to make this test fail when expected. rw_bare_repo._working_tree_dir = None - contents = 'This is a StringIO file' + contents = b'This is a BytesIO file' filesize = len(contents) - fileobj = StringIO(contents) + fileobj = BytesIO(contents) filename = 'my-imaginary-file' istream = rw_bare_repo.odb.store( IStream(Blob.type, filesize, fileobj)) |