pytest
pytest suites: test style rules, test-name prefixes, and a coverage floor before every push. It requires python. The Tests and coverage guide explains the setup.
Checks
Section titled “Checks”| Check | Stage | Level | What it does |
|---|---|---|---|
pytest/coverage |
push |
recommended |
Runs pytest with coverage, and fails on a broken test or a covered share under the floor. |
Settings
Section titled “Settings”| Setting | What it sets |
|---|---|
coverage.lines |
The minimum percentage of source lines covered by tests. |
coverage.branches |
The minimum percentage of source branches covered by tests. |
coverage.functions |
The minimum percentage of source functions covered by tests. |
coverage.statements |
The minimum percentage of source statements covered by tests. |
Selected when
Section titled “Selected when”gspot selects it in a scope with filenames conftest.py, pytest.ini, or dependencies pytest.
Tools and versions
Section titled “Tools and versions”| Tool | Version |
|---|---|
| pytest | Any |
| pytest-cov | Any |