summaryrefslogtreecommitdiff
path: root/pkg_resources/tests/test_find_distributions.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2021-04-25 18:05:55 -0400
committerJason R. Coombs <jaraco@jaraco.com>2021-04-25 18:05:55 -0400
commitb720937d0af9e8382c8b9e00b2c0d5715b7cfbe5 (patch)
treec29ce9e7423c4f89e79634991941e5bdf9d07a15 /pkg_resources/tests/test_find_distributions.py
parent8b494633df0f6770946092498aed76fd30be99b1 (diff)
parentb5fa6ad11e1344648b470ff0d847a7d940b4c99d (diff)
downloadpython-setuptools-git-feature/distutils-docs.tar.gz
Merge branch 'main' into feature/distutils-docsfeature/distutils-docs
Diffstat (limited to 'pkg_resources/tests/test_find_distributions.py')
-rw-r--r--pkg_resources/tests/test_find_distributions.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/pkg_resources/tests/test_find_distributions.py b/pkg_resources/tests/test_find_distributions.py
index f9594422..b01b4827 100644
--- a/pkg_resources/tests/test_find_distributions.py
+++ b/pkg_resources/tests/test_find_distributions.py
@@ -32,3 +32,12 @@ class TestFindDistributions:
assert [dist.project_name for dist in dists] == ['my-test-package']
dists = pkg_resources.find_distributions(str(target_dir), only=True)
assert not list(dists)
+
+ def test_zipped_sdist_one_level_removed(self, target_dir):
+ (TESTS_DATA_DIR / 'my-test-package-zip').copy(target_dir)
+ dists = pkg_resources.find_distributions(
+ str(target_dir / "my-test-package.zip"))
+ assert [dist.project_name for dist in dists] == ['my-test-package']
+ dists = pkg_resources.find_distributions(
+ str(target_dir / "my-test-package.zip"), only=True)
+ assert not list(dists)