diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2016-05-30 18:58:30 +0200 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2016-05-30 18:58:30 +0200 |
commit | 79fdaf349fa8ad3524f67f1ef86c38ecfc317585 (patch) | |
tree | 12850b29d57db446ea3a3060da14bd0312ef0687 /git/test/test_commit.py | |
parent | f5089d9d6c303b47936a741b7bdf37293ec3a1c6 (diff) | |
parent | 79c99c0f66c8f3c8d13258376c82125a23b1b5c8 (diff) | |
download | gitpython-79fdaf349fa8ad3524f67f1ef86c38ecfc317585.tar.gz |
Merge pull request #456 from gitpython-developers/fix-for-invalid-data-in-commits
Add test case as example of Git commit with invalid data
Diffstat (limited to 'git/test/test_commit.py')
-rw-r--r-- | git/test/test_commit.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/git/test/test_commit.py b/git/test/test_commit.py index 23b7154a..ea8cd9af 100644 --- a/git/test/test_commit.py +++ b/git/test/test_commit.py @@ -306,6 +306,13 @@ class TestCommit(TestBase): # it appears cmt.author.__repr__() + def test_invalid_commit(self): + cmt = self.rorepo.commit() + cmt._deserialize(open(fixture_path('commit_invalid_data'), 'rb')) + + assert cmt.author.name == u'E.Azer Ko�o�o�oculu', cmt.author.name + assert cmt.author.email == 'azer@kodfabrik.com', cmt.author.email + def test_gpgsig(self): cmt = self.rorepo.commit() cmt._deserialize(open(fixture_path('commit_with_gpgsig'), 'rb')) |