diff options
author | 2023-02-10 14:31:15 +0100 | |
---|---|---|
committer | 2023-02-12 20:00:43 +0100 | |
commit | e08af0656e81cdcc02f9e05d2e83546ebf1673c5 (patch) | |
tree | efb9f492cf21b206b51ef9b16aa6795d6cb9f885 /eclass/tests/pypi.sh | |
parent | pypi.eclass: Add a name normalization function (diff) | |
download | gentoo-e08af0656e81cdcc02f9e05d2e83546ebf1673c5.tar.gz gentoo-e08af0656e81cdcc02f9e05d2e83546ebf1673c5.tar.bz2 gentoo-e08af0656e81cdcc02f9e05d2e83546ebf1673c5.zip |
pypi.eclass: Normalize wheel filenames
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass/tests/pypi.sh')
-rwxr-xr-x | eclass/tests/pypi.sh | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/eclass/tests/pypi.sh b/eclass/tests/pypi.sh index 67b2c3c481fb..111b61380fe4 100755 --- a/eclass/tests/pypi.sh +++ b/eclass/tests/pypi.sh @@ -29,4 +29,37 @@ 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 +test-eq "pypi_wheel_name Flask-BabelEx 4 py2.py3" \ + flask_babelex-4-py2.py3-none-any.whl +test-eq "pypi_wheel_name cryptography 39.0.1 cp36 abi3-manylinux_2_28_x86_64" \ + cryptography-39.0.1-cp36-abi3-manylinux_2_28_x86_64.whl + +test-eq "pypi_wheel_url" \ + https://files.pythonhosted.org/packages/py3/F/Foo.Bar/foo_bar-1.2.3-py3-none-any.whl +test-eq "pypi_wheel_url Flask-BabelEx" \ + https://files.pythonhosted.org/packages/py3/F/Flask-BabelEx/flask_babelex-1.2.3-py3-none-any.whl +test-eq "pypi_wheel_url Flask-BabelEx 4" \ + https://files.pythonhosted.org/packages/py3/F/Flask-BabelEx/flask_babelex-4-py3-none-any.whl +test-eq "pypi_wheel_url Flask-BabelEx 4 py2.py3" \ + https://files.pythonhosted.org/packages/py2.py3/F/Flask-BabelEx/flask_babelex-4-py2.py3-none-any.whl +test-eq "pypi_wheel_url 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 + +test-eq "pypi_wheel_url --unpack" \ + "https://files.pythonhosted.org/packages/py3/F/Foo.Bar/foo_bar-1.2.3-py3-none-any.whl -> foo_bar-1.2.3-py3-none-any.whl.zip" +test-eq "pypi_wheel_url --unpack Flask-BabelEx" \ + "https://files.pythonhosted.org/packages/py3/F/Flask-BabelEx/flask_babelex-1.2.3-py3-none-any.whl -> flask_babelex-1.2.3-py3-none-any.whl.zip" +test-eq "pypi_wheel_url --unpack Flask-BabelEx 4" \ + "https://files.pythonhosted.org/packages/py3/F/Flask-BabelEx/flask_babelex-4-py3-none-any.whl -> flask_babelex-4-py3-none-any.whl.zip" +test-eq "pypi_wheel_url --unpack Flask-BabelEx 4 py2.py3" \ + "https://files.pythonhosted.org/packages/py2.py3/F/Flask-BabelEx/flask_babelex-4-py2.py3-none-any.whl -> flask_babelex-4-py2.py3-none-any.whl.zip" +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" + texit |