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

Include test files so test suite passes from PyPi #34

Merged
merged 1 commit into from
Sep 24, 2021

Conversation

frenchie
Copy link
Contributor

@frenchie frenchie commented Sep 20, 2021

I've submitted puremagic to the FreeBSD ports tree - see FreeBSD report https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=258593

While generating the port, I noticed that the package distributed from PyPi is missing the test data files so the test suite will always fail if the source is fetched from there. The python test file (test_common_extensions.py) gets pulled into the python package because it has a .py extension, but the data files the tests run against are missed because they do not.

This commit grafts in test/ (pulls in everything) and then excludes pyc, pyo & pyd files per the recommended way of doing this in the python packaging manual.

FreeBSD preference is to pull all python packages from PyPi and to include test-suites where available. For right now, the options are either omit the test suite or pull from GitHub.

Package distributed from PyPi is missing the test data files so the test suite will always fail if the source is fetched from there. The test python files get pulled into the package because they have a .py extension, but the data files the test runs again are missed because they do not.

This commit grafts in test/ (pulls in everything) and then excludes pyc, pyo & pyd files per the recommended way of doing this in the python packaging manual.
@cdgriffith cdgriffith changed the base branch from master to develop September 24, 2021 14:00
@cdgriffith cdgriffith merged commit a26a9e3 into cdgriffith:develop Sep 24, 2021
@cdgriffith cdgriffith mentioned this pull request Sep 24, 2021
cdgriffith added a commit that referenced this pull request Sep 24, 2021
* Include test files so test suite passes from PyPi (#34)
* Install from pypy added to readme (#33)
* setup.py cleanup #31 , pre-commit updates, year bump, version bump

Co-authored-by: James French <[email protected]>
Co-authored-by: Sander <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants