Skip to content

Commit eb839a6

Browse files
committed
Add test to ensure that EntryPoints are sortable. Fixes #267.
1 parent 155bc48 commit eb839a6

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/test_main.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,17 @@ def test_module(self):
257257
def test_attr(self):
258258
assert self.ep.attr is None
259259

260+
def test_sortable(self):
261+
"""
262+
EntryPoint objects are sortable, but result is undefined.
263+
"""
264+
sorted(
265+
[
266+
EntryPoint('b', 'val', 'group'),
267+
EntryPoint('a', 'val', 'group'),
268+
]
269+
)
270+
260271

261272
class FileSystem(
262273
fixtures.OnSysPath, fixtures.SiteDir, fixtures.FileBuilder, unittest.TestCase

0 commit comments

Comments
 (0)