Skip to content

Commit

Permalink
Apply recommended pytest config
Browse files Browse the repository at this point in the history
See scientific python development guide
  • Loading branch information
ffl096 committed Dec 10, 2024
1 parent 19a8699 commit f0ce3c8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
3 changes: 0 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
default_language_version:
python: python3.11

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
Expand Down
12 changes: 10 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ ignore = ["E501"] # line too long
[tool.ruff.lint.pydocstyle]
convention = "numpy"

[tool.ruff.per-file-ignores]
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F403"]

[tool.setuptools.packages.find]
Expand All @@ -118,7 +118,15 @@ disable_error_code = ["import-untyped"]
plugins = "numpy.typing.mypy_plugin"

[tool.pytest.ini_options]
addopts = "--capture=no"
minversion = "7.0"
addopts = ["-ra", "--showlocals", "--strict-markers", "--strict-config"]
xfail_strict = true
filterwarnings = [
"error",
"ignore::scipy.sparse._base.SparseEfficiencyWarning",
]
log_cli_level = "info"
testpaths = ["test"]

[tool.numpydoc_validation]
checks = [
Expand Down

0 comments on commit f0ce3c8

Please sign in to comment.