Skip to content

Commit 272b692

Browse files
authored
Improve coverage config (#10530)
Coverage 7.2 added exclude_also which extends exclude_lines and is now the preferred method to add new exclude patterns. https://coverage.readthedocs.io/en/7.10.6/excluding.html#advanced-exclusion
1 parent 7bef3af commit 272b692

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.coveragerc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,7 @@ include =
77
pylint/*
88
omit =
99
*/test/*
10-
exclude_lines =
11-
# Re-enable default pragma
12-
pragma: no cover
13-
10+
exclude_also =
1411
# Debug-only code
1512
def __repr__
1613

@@ -20,3 +17,6 @@ exclude_lines =
2017

2118
# Abstract methods are not executed during pytest runs
2219
raise NotImplementedError()
20+
21+
# Fallback cases which should never be executed
22+
raise AssertionError

0 commit comments

Comments
 (0)