Skip to content

Commit b4661fd

Browse files
committed
Add test capturing missed expectation on extras. Ref #369.
1 parent 590e31d commit b4661fd

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

importlib_metadata/__init__.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,15 @@ class EntryPoint(DeprecatedTuple):
157157
See `the packaging docs on entry points
158158
<https://packaging.python.org/specifications/entry-points/>`_
159159
for more information.
160+
161+
>>> ep = EntryPoint(
162+
... name=None, group=None, value='package.module:attr [extra1, extra2]')
163+
>>> ep.module
164+
'package.module'
165+
>>> ep.attr
166+
'attr'
167+
>>> ep.extras
168+
['extra1', 'extra2']
160169
"""
161170

162171
pattern = re.compile(

0 commit comments

Comments
 (0)