8ea00f5185
CI / unit_tests (push) Has been cancelled
CI / benchmark-publish (push) Has been cancelled
CI / lint (push) Has been cancelled
CI / typecheck (push) Has been cancelled
CI / security (push) Has been cancelled
CI / quality (push) Has been cancelled
CI / integration_tests (push) Has been cancelled
CI / e2e_tests (push) Has been cancelled
CI / coverage (push) Has been cancelled
CI / benchmark-regression (push) Has been cancelled
CI / build (push) Has been cancelled
CI / push-validation (push) Has been cancelled
CI / status-check (push) Has been cancelled
CI / docker (push) Has been cancelled
CI / helm (push) Has been cancelled
Co-authored-by: Jeffrey Phillips Freeman <the@jeffreyfreeman.me> Co-committed-by: Jeffrey Phillips Freeman <the@jeffreyfreeman.me>
60 lines
2.5 KiB
Gherkin
60 lines
2.5 KiB
Gherkin
Feature: Coverage threshold configuration
|
|
The project enforces a minimum 97% code coverage threshold across multiple
|
|
configuration files. This feature validates that pyproject.toml, noxfile.py,
|
|
the CI workflow, and the nightly quality workflow are all correctly configured
|
|
to enforce and report coverage thresholds.
|
|
|
|
# -- pyproject.toml coverage configuration --
|
|
|
|
Scenario: Coverage run section exists in pyproject.toml
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage run section should exist
|
|
|
|
Scenario: Coverage source includes src directory
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage source should include "src"
|
|
|
|
Scenario: Coverage branch tracking is enabled
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage branch tracking should be enabled
|
|
|
|
Scenario: Coverage data file is stored under build directory
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage data file should be "build/.coverage"
|
|
|
|
Scenario: Coverage HTML report directory is under build
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage html directory should be "build/htmlcov"
|
|
|
|
Scenario: Coverage XML output is under build directory
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage xml output should be "build/coverage.xml"
|
|
|
|
Scenario: Coverage omit patterns exclude test directories
|
|
Given the pyproject toml file is loaded for coverage check
|
|
Then the coverage omit patterns should include "*/tests/*"
|
|
|
|
# -- noxfile.py coverage session --
|
|
|
|
Scenario: Noxfile defines a coverage_report session
|
|
Given the noxfile py is loaded for coverage check
|
|
Then the noxfile should define a coverage_report session
|
|
|
|
# @tdd_issue @tdd_issue_4227 @tdd_expected_fail @skip
|
|
@skip
|
|
Scenario: Noxfile enforces fail-under threshold of at least 97
|
|
Given the noxfile py is loaded for coverage check
|
|
Then the noxfile should contain a fail-under threshold of at least 97
|
|
|
|
# -- CI workflow coverage enforcement --
|
|
|
|
Scenario: CI workflow references nox coverage_report session
|
|
Given the ci workflow file is loaded for coverage check
|
|
Then the ci workflow should reference nox coverage_report session
|
|
|
|
# -- Nightly quality workflow coverage enforcement --
|
|
|
|
Scenario: Nightly workflow enforces coverage threshold via --coverage-min
|
|
Given the nightly quality workflow file is loaded for coverage check
|
|
Then the nightly workflow should use a fail-under of at least 85
|