Add ignore list for coverage (pytest), rename json default function to default_isoformat

This commit is contained in:
Clemens Schwaighofer
2025-10-27 10:05:31 +09:00
parent caf0039de4
commit c7b38b0d70
3 changed files with 38 additions and 15 deletions

View File

@@ -67,3 +67,26 @@ init-hook='import sys; sys.path.append("src/")'
testpaths = [
"tests",
]
[tool.coverage.run]
omit = [
"*/tests/*",
"*/test_*.py",
"*/__init__.py"
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"def __str__",
"raise AssertionError",
"raise NotImplementedError",
"if __name__ == .__main__.:"
]
exclude_also = [
"def __.*__\\(",
"def __.*\\(",
"def _.*\\(",
]