Skip to content

Commit 11b483d

Browse files
committed
Add test capturing missed expectation. Ref #117.
1 parent 0ea5172 commit 11b483d

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

importlib_metadata/tests/test_zip.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
import sys
22
import unittest
33

4-
from .. import distribution, entry_points, files, PackageNotFoundError, version
4+
from .. import (
5+
distribution, entry_points, files, PackageNotFoundError,
6+
version, distributions,
7+
)
58

69
try:
710
from importlib.resources import path
@@ -52,6 +55,10 @@ def test_files(self):
5255
path = str(file.dist.locate_file(file))
5356
assert '.whl/' in path, path
5457

58+
def test_one_distribution(self):
59+
dists = list(distributions(path=sys.path[:1]))
60+
assert len(dists) == 1
61+
5562

5663
class TestEgg(TestZip):
5764
def setUp(self):

0 commit comments

Comments
 (0)