Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_metadata_nominal fails for git tarball #13

Closed
OTLabs opened this issue Feb 14, 2024 · 2 comments · Fixed by #12
Closed

test_metadata_nominal fails for git tarball #13

OTLabs opened this issue Feb 14, 2024 · 2 comments · Fixed by #12
Assignees
Labels
bug Something isn't working
Milestone

Comments

@OTLabs
Copy link

OTLabs commented Feb 14, 2024

I am building the package for Alpine Linux and test_metadata_nominal fails as I use git tarball:

=================================== FAILURES ===================================
____________________________ test_metadata_nominal _____________________________

metadata = {'authors': [{'email': 'dev@openzim.org', 'name': 'openZIM'}], 'classifiers': ['License :: OSI Approved :: GNU General...: Python :: 3.11'], 'dynamic': ['authors', 'classifiers', 'keywords', 'license', 'urls'], 'keywords': ['openzim'], ...}

    def test_metadata_nominal(metadata):
        update(
            root=str(Path(os.path.dirname(os.path.abspath(__file__))).parent),
            config={},
            metadata=metadata,
        )
    
        assert metadata["authors"] == [{"email": "dev@openzim.org", "name": "openZIM"}]
        assert metadata["classifiers"] == [
            "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
            "Programming Language :: Python :: 3",
            "Programming Language :: Python :: 3.10",
            "Programming Language :: Python :: 3.11",
        ]
        assert metadata["keywords"] == ["openzim"]
        assert metadata["license"] == {"text": "GPL-3.0-or-later"}
>       assert metadata["urls"] == {
            "Donate": "https://www.kiwix.org/en/support-us/",
            "Homepage": "https://github.com/openzim/hatch-openzim",
        }
E       AssertionError: assert {'Donate': 'h...ww.kiwix.org'} == {'Donate': 'h...atch-openzim'}
E         
E         Omitting 1 identical items, use -vv to show
E         Differing items:
E         {'Homepage': 'https://www.kiwix.org'} != {'Homepage': 'https://github.com/openzim/hatch-openzim'}
E         Use -v to get more diff

/home/builder/aports/testing/py3-hatch-openzim/src/hatch-openzim-0.1.0/tests/test_metadata.py:44: AssertionError
@benoit74 benoit74 added this to the 0.2.0 milestone Feb 14, 2024
@benoit74 benoit74 added the bug Something isn't working label Feb 14, 2024
@benoit74
Copy link
Collaborator

Thank you for reporting this. I will fix this (adjust the expected Homepage URL when tests are ran from a git tarball). You can safely ignore this test in the mean time if needed (that been said, I plan to do this for 0.2.0 and I expect to release 0.2.0 on Friday ...)

@OTLabs
Copy link
Author

OTLabs commented Feb 14, 2024

Thank you! I have submitted corresponding MR already (ignoring this test), will update promptly with new version as it become available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants