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

[FR] Extend the default tests glob inclusion #4460

Open
1 task done
webknjaz opened this issue Jul 6, 2024 · 0 comments
Open
1 task done

[FR] Extend the default tests glob inclusion #4460

webknjaz opened this issue Jul 6, 2024 · 0 comments
Labels
enhancement Needs Triage Issues that need to be evaluated for severity and status.

Comments

@webknjaz
Copy link
Member

webknjaz commented Jul 6, 2024

What's the problem this feature will solve?

The docs @ https://setuptools.pypa.io/en/latest/userguide/miscellaneous.html#controlling-files-in-the-distribution say:

  • Files that match the following glob patterns: tests/test*.py, test/test*.py;

Test files that have _test suffix in their base name are not included automatically. This is one of the common naming conventions. They should.

Describe the solution you'd like

Including test files that have _test suffix in base name would be super useful. Additionally, does this recognize well-known names like conftest.py?

Alternative Solutions

No response

Additional context

The example is a pyproject.toml looking as follows:

[build-system]
requires = [
  "setuptools",
]
build-backend = "setuptools.build_meta"

[project]
name = "lokiverse"
version = "1.0.0"
dependencies = [
  "cheroot",
]

The project has an src/ layout with top-level tests/ and the file at tests/api_test.py is not included.

Code of Conduct

  • I agree to follow the PSF Code of Conduct
@webknjaz webknjaz added enhancement Needs Triage Issues that need to be evaluated for severity and status. labels Jul 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Needs Triage Issues that need to be evaluated for severity and status.
Projects
None yet
Development

No branches or pull requests

1 participant