File tree Expand file tree Collapse file tree 2 files changed +14
-14
lines changed
Expand file tree Collapse file tree 2 files changed +14
-14
lines changed Original file line number Diff line number Diff line change 1515from importlib_metadata import (
1616 MetadataPathFinder ,
1717 _compat ,
18- distributions ,
1918 version ,
2019)
2120
@@ -64,16 +63,3 @@ def test_search_dist_dirs(self):
6463 """
6564 res = MetadataPathFinder ._search_paths ('any-name' , [])
6665 assert list (res ) == []
67-
68- def test_interleaved_discovery (self ):
69- """
70- When the search is cached, it is
71- possible for searches to be interleaved, so make sure
72- those use-cases are safe.
73-
74- Ref #293
75- """
76- dists = distributions ()
77- next (dists )
78- version ('importlib_metadata' )
79- next (dists )
Original file line number Diff line number Diff line change @@ -204,6 +204,20 @@ def test_invalid_usage(self):
204204 with self .assertRaises (ValueError ):
205205 list (distributions (context = 'something' , name = 'else' ))
206206
207+ def test_interleaved_discovery (self ):
208+ """
209+ Ensure interleaved searches are safe.
210+
211+ When the search is cached, it is possible for searches to be
212+ interleaved, so make sure those use-cases are safe.
213+
214+ Ref #293
215+ """
216+ dists = distributions ()
217+ next (dists )
218+ version ('egginfo-pkg' )
219+ next (dists )
220+
207221
208222class DirectoryTest (fixtures .OnSysPath , fixtures .SiteDir , unittest .TestCase ):
209223 def test_egg_info (self ):
You can’t perform that action at this time.
0 commit comments