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

sdist tests #116

Open
jayvdb opened this issue Jul 19, 2020 · 3 comments
Open

sdist tests #116

jayvdb opened this issue Jul 19, 2020 · 3 comments

Comments

@jayvdb
Copy link

jayvdb commented Jul 19, 2020

Hi, I am packaging Divio Django CMS packages for openSUSE, and I always want to run the tests in my builds to verify that the package is working, and breaks when dependencies become incompatible.

The tests in this repo are included in the sdist, which is great, but they can not be used.
setup.py includes

test_suite='tests.settings.run'

However tests/settings/ are not included in the sdist.

The packaging is happening at https://build.opensuse.org/package/show/home:jayvdb:django/python-djangocms-bootstrap4

The collection of other Divio packages can be found at
https://build.opensuse.org/project/show/home:jayvdb:django

I encountered similar problems with

  • djangocms-attributes-field
  • djangocms-snippet
  • djangocms-link
  • aldryn-apphooks-config
  • aldryn-translation-tools

And lots of packages don't include or declare their tests, such as djangocms-icon.

Also, all setup.py use license='BSD'. It would be nice if they used "BSD-3-Clause", the https://spdx.org identifier for the specific license being used.

@FinalAngel
Copy link
Member

@jayvdb would removing the exclude=['tests'] from packages=find_packages(exclude=['tests']), in the setup.py file help?

@jayvdb
Copy link
Author

jayvdb commented Aug 6, 2020

No, that tell setuptools to include tests as part of the installed library, which is wrong. MANIFEST.in is the typical solution. There are alternatives, if using tools other than just setuptools. e.g. dephell automatically adds tests to the sdist.

@FinalAngel
Copy link
Member

@jayvdb I'm happy for a PR suggestion that then can be applied to the other addons as well :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants