-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpytest.ini
More file actions
29 lines (23 loc) · 770 Bytes
/
Copy pathpytest.ini
File metadata and controls
29 lines (23 loc) · 770 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
[pytest]
addopts = -v -s --disable-warnings --cov=app --cov-report=term-missing
testpaths = test
filterwarnings=
ignore::DeprecationWarning
ignore::UserWarning
[coverage:run]
# 2. The Omit Rule (Crucial)
# This tells the coverage tracker to completely ignore files that don't need tests.
# If you don't omit your migrations, you will never reach 100% coverage.
omit =
app/alembic/*
app/tests/*
*/__init__.py
app/todos.py
[coverage:report]
# 3. The Exclusion Rules
# Sometimes you have code that is physically impossible to test or is just for debugging.
# If you put "# pragma: no cover" next to a line of Python, this rule tells pytest-cov to ignore it.
exclude_lines =
pragma: no cover
def __repr__
if __name__ == .__main__.: