django - pytest-cov cover many applications at once -
i built django project many applications. want generate coverage report these applications. testing purposes, use py.test, pytest-django , pytest-cov. far, can generate report typing app names manually on command line:
py.test --cov-report html --cov=app1 --cov=app2 --cov=app3 --cov=app4 */tests.py
does pytest-cov have way specify applications simple expression?
assuming you're using bash, use expand parameters:
py.test --cov-report html --cov=app{1,2,3,4} */tests.py
you add parameters pytest.ini
they're passed automatically on each invocation.
Comments
Post a Comment