File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -65,6 +65,13 @@ ignore_errors = true
6565module = [" graphviz" , " invoke.*" ]
6666ignore_missing_imports = true
6767
68+ [tool .coverage .run ]
69+ source = [" lib/rule_engine" ]
70+ omit = [" lib/rule_engine/_vendor/*" ]
71+
72+ [tool .coverage .report ]
73+ show_missing = true
74+
6875[tool .setuptools ]
6976package-dir = {"" = " lib" }
7077
Original file line number Diff line number Diff line change @@ -23,10 +23,14 @@ def docs(c):
2323 c .run ('uv run sphinx-build -b html -a -E -v docs/source docs/html' )
2424
2525
26- @task
27- def tests (c ):
26+ @task ( help = { 'coverage' : 'Measure test coverage and print a report.' })
27+ def tests (c , coverage = False ):
2828 """Run unit tests."""
29- c .run ('uv run python -m unittest -v' , pty = True )
29+ if coverage :
30+ c .run ('uv run coverage run -m unittest -v' , pty = True )
31+ c .run ('uv run coverage report' )
32+ else :
33+ c .run ('uv run python -m unittest -v' , pty = True )
3034
3135@task
3236def typechecks (c ):
You can’t perform that action at this time.
0 commit comments