Search code examples
pythonpackagingsetuptoolstesting

Adding tests to sdist, but not installing


I'd like to add tests to the sdist package in my setuptools distribution, but I don't want them installed / in bdist. I already have:

setup(
   ...
   packages = find_packages(exclude='tests'),
   test_suite = "tests",
   ...
)

But currently the tests/* are always included. How can I change that?


Solution

  • in MANIFEST.in put

    include tests/*