diff options
author | Aarni Koskela <akx@iki.fi> | 2018-07-20 13:36:22 +0300 |
---|---|---|
committer | Aarni Koskela <akx@iki.fi> | 2018-07-20 13:36:22 +0300 |
commit | 3f1dffbb2dffc88957384fc4af378003299c68db (patch) | |
tree | 264899fb046c7baa0f7e1e5eeccd23fd69836d88 /tests | |
parent | 359ecffca479dfe032d0f7210d5cd8160599c816 (diff) | |
download | babel-3f1dffbb2dffc88957384fc4af378003299c68db.tar.gz |
Fix pofile test failure
Diffstat (limited to 'tests')
-rw-r--r-- | tests/messages/test_pofile.py | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/tests/messages/test_pofile.py b/tests/messages/test_pofile.py index 5313329..9872e9d 100644 --- a/tests/messages/test_pofile.py +++ b/tests/messages/test_pofile.py @@ -456,16 +456,8 @@ msgstr[2] "Vohs [text]" ''' # Catalog not created, throws Unicode Error buf = StringIO(invalid_po) - output = None - - # This should only be thrown under py27 - if sys.version_info.major == 2: - with self.assertRaises(UnicodeEncodeError): - output = pofile.read_po(buf, locale='fr', abort_invalid=False) - assert not output - else: - output = pofile.read_po(buf, locale='fr', abort_invalid=False) - assert isinstance(output, Catalog) + output = pofile.read_po(buf, locale='fr', abort_invalid=False) + assert isinstance(output, Catalog) # Catalog not created, throws PoFileError buf = StringIO(invalid_po_2) |