Skip to content

Commit

Permalink
Merge pull request #88 from hugovk/add-3.9
Browse files Browse the repository at this point in the history
Declare support for Python 3.9
  • Loading branch information
kjd authored Oct 17, 2020
2 parents e7338bc + 4b3e6fd commit cc273f8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
1 change: 0 additions & 1 deletion idna/uts46data.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# This file is automatically generated by tools/idna-data
# vim: set fileencoding=utf-8 :

"""IDNA Mapping Table from UTS46."""

Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ def main():
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Topic :: Internet :: Name Service (DNS)',
Expand Down
8 changes: 2 additions & 6 deletions tests/test_idna_codec.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,8 @@ def testIncrementalDecoder(self):
)

for decoded, encoded in incremental_tests:
if sys.version_info[0] == 2:
self.assertEqual("".join(codecs.iterdecode(encoded, "idna")),
decoded)
else:
self.assertEqual("".join(codecs.iterdecode((bytes([c]) for c in encoded), "idna")),
decoded)
self.assertEqual("".join(codecs.iterdecode((bytes([c]) for c in encoded), "idna")),
decoded)

decoder = codecs.getincrementaldecoder("idna")()
self.assertEqual(decoder.decode(b"xn--xam", ), "")
Expand Down

0 comments on commit cc273f8

Please sign in to comment.