-
Notifications
You must be signed in to change notification settings - Fork 87
Open
Description
The pyproject.toml file can be used to store pytest's config (otherwise declared in a separate pytest.ini file), see:
https://docs.pytest.org/en/6.2.x/customize.html#pyproject-toml
It could be valuable to add the recommended options for pytest:
- Treat warnings as errors by default: https://docs.pytest.org/en/7.2.x/reference/reference.html#confval-filterwarnings
- Use
importlibimport mode: https://docs.pytest.org/en/7.2.x/explanation/goodpractices.html#tests-outside-application-code
# pyproject.toml
[tool.pytest.ini_options]
filterwarnings = ["error"]
addopts = ["--import-mode=importlib"]Note that the importlib option probably unnecessitates placing the hypermodern_python package in the src folder (src/hypermodern_python):
-> src/hypermodern_pythonhypermodern_python
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels