diff options
author | 2023-02-10 14:40:54 +0100 | |
---|---|---|
committer | 2023-02-12 20:00:44 +0100 | |
commit | cb6c347eb94f7258fa1aecee2107cd25e5c3a5f7 (patch) | |
tree | 59ba49f0d2e2fa9c7c46f5ebe76755f1fa5aeea5 /eclass/tests | |
parent | pypi.eclass: Add `--unpack` to usage error in pypi_wheel_url (diff) | |
download | gentoo-cb6c347eb94f7258fa1aecee2107cd25e5c3a5f7.tar.gz gentoo-cb6c347eb94f7258fa1aecee2107cd25e5c3a5f7.tar.bz2 gentoo-cb6c347eb94f7258fa1aecee2107cd25e5c3a5f7.zip |
pypi.eclass: Normalize sdist filenames by default
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass/tests')
-rwxr-xr-x | eclass/tests/pypi.sh | 27 |
1 files changed, 24 insertions, 3 deletions
diff --git a/eclass/tests/pypi.sh b/eclass/tests/pypi.sh index 111b61380fe4..385b1c028bce 100755 --- a/eclass/tests/pypi.sh +++ b/eclass/tests/pypi.sh @@ -5,6 +5,9 @@ EAPI=8 source tests-common.sh || exit +PN=Foo.Bar +PV=1.2.3 + inherit pypi test-eq() { @@ -29,9 +32,6 @@ test-eq "pypi_normalize_name foo___bar" foo_bar test-eq "pypi_normalize_name Flask-BabelEx" flask_babelex test-eq "pypi_normalize_name jaraco.context" jaraco_context -PN=Foo.Bar -PV=1.2.3 - test-eq "pypi_wheel_name" foo_bar-1.2.3-py3-none-any.whl test-eq "pypi_wheel_name Flask-BabelEx" flask_babelex-1.2.3-py3-none-any.whl test-eq "pypi_wheel_name Flask-BabelEx 4" flask_babelex-4-py3-none-any.whl @@ -62,4 +62,25 @@ test-eq "pypi_wheel_url --unpack Flask-BabelEx 4 py2.py3" \ test-eq "pypi_wheel_url --unpack cryptography 39.0.1 cp36 abi3-manylinux_2_28_x86_64" \ "https://files.pythonhosted.org/packages/cp36/c/cryptography/cryptography-39.0.1-cp36-abi3-manylinux_2_28_x86_64.whl -> cryptography-39.0.1-cp36-abi3-manylinux_2_28_x86_64.whl.zip" +test-eq "pypi_sdist_url" \ + https://files.pythonhosted.org/packages/source/F/Foo.Bar/foo_bar-1.2.3.tar.gz +test-eq "pypi_sdist_url Flask-BabelEx" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/flask_babelex-1.2.3.tar.gz +test-eq "pypi_sdist_url Flask-BabelEx 4" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/flask_babelex-4.tar.gz +test-eq "pypi_sdist_url Flask-BabelEx 4 .zip" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/flask_babelex-4.zip + +test-eq "pypi_sdist_url --no-normalize" \ + https://files.pythonhosted.org/packages/source/F/Foo.Bar/Foo.Bar-1.2.3.tar.gz +test-eq "pypi_sdist_url --no-normalize Flask-BabelEx" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/Flask-BabelEx-1.2.3.tar.gz +test-eq "pypi_sdist_url --no-normalize Flask-BabelEx 4" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/Flask-BabelEx-4.tar.gz +test-eq "pypi_sdist_url --no-normalize Flask-BabelEx 4 .zip" \ + https://files.pythonhosted.org/packages/source/F/Flask-BabelEx/Flask-BabelEx-4.zip + +test-eq 'declare -p SRC_URI' \ + 'declare -- SRC_URI="https://files.pythonhosted.org/packages/source/F/Foo.Bar/foo_bar-1.2.3.tar.gz"' + texit |