Skip to content

Commit

Permalink
cross port importlib-metadata PR GH-76 (GH-13903)
Browse files Browse the repository at this point in the history
https://gitlab.com/python-devs/importlib_metadata/merge_requests/76
(cherry picked from commit 65e5860)

Co-authored-by: Anthony Sottile <asottile@umich.edu>
  • Loading branch information
miss-islington and asottile authored Jun 7, 2019
1 parent 606ac58 commit 3b5bac2
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Lib/importlib/metadata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ def _from_config(cls, config):
@classmethod
def _from_text(cls, text):
config = ConfigParser()
# case sensitive: https://stackoverflow.com/q/1611799/812183
config.optionxform = str
try:
config.read_string(text)
except AttributeError: # pragma: nocover
Expand Down
Binary file modified Lib/test/test_importlib/data/example-21.12-py3-none-any.whl
Binary file not shown.
Binary file modified Lib/test/test_importlib/data/example-21.12-py3.6.egg
Binary file not shown.
2 changes: 2 additions & 0 deletions Lib/test/test_importlib/test_zip.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ def test_zip_entry_points(self):
scripts = dict(entry_points()['console_scripts'])
entry_point = scripts['example']
self.assertEqual(entry_point.value, 'example:main')
entry_point = scripts['Example']
self.assertEqual(entry_point.value, 'example:main')

def test_missing_metadata(self):
self.assertIsNone(distribution('example').read_text('does not exist'))
Expand Down

0 comments on commit 3b5bac2

Please sign in to comment.