fix(tests): update coverage job dependency assertions to unit_tests
CI / benchmark-publish (pull_request) Has been skipped
CI / benchmark-regression (pull_request) Failing after 36s
CI / lint (pull_request) Successful in 54s
CI / quality (pull_request) Successful in 58s
CI / build (pull_request) Successful in 44s
CI / push-validation (pull_request) Successful in 28s
CI / typecheck (pull_request) Successful in 1m12s
CI / helm (pull_request) Successful in 34s
CI / security (pull_request) Successful in 1m15s
CI / integration_tests (pull_request) Failing after 4m18s
CI / e2e_tests (pull_request) Successful in 4m39s
CI / unit_tests (pull_request) Failing after 7m10s
CI / coverage (pull_request) Has been skipped
CI / docker (pull_request) Has been skipped
CI / status-check (pull_request) Failing after 4s

The coverage job in ci.yml was updated to depend on unit_tests only
(removing lint/typecheck which are independent static-analysis jobs).
Two BDD scenarios still asserted the old lint+typecheck dependency,
causing unit_tests gate failures. Updated both scenarios and the
step definition to assert the correct unit_tests dependency.

ISSUES CLOSED: #1641
This commit is contained in:
2026-06-06 23:48:12 -04:00
parent d1d492d859
commit da439cd1fe
3 changed files with 7 additions and 12 deletions
+2 -3
View File
@@ -54,11 +54,10 @@ Feature: CI workflow validation
When I parse the CI workflow YAML
Then the workflow env should set "PYTHON_VERSION" to "3.13"
Scenario: CI workflow coverage job depends on lint and typecheck
Scenario: CI workflow coverage job depends on unit_tests
Given the CI workflow file at ".forgejo/workflows/ci.yml"
When I parse the CI workflow YAML
Then the job "coverage" should depend on "lint"
And the job "coverage" should depend on "typecheck"
Then the job "coverage" should depend on "unit_tests"
Scenario: All required nox sessions are referenced
Given the CI workflow file at ".forgejo/workflows/ci.yml"
@@ -44,10 +44,10 @@ Feature: Coverage threshold enforcement
When I parse the coverage job from the CI workflow
Then the coverage job should run nox -s coverage_report
Scenario: CI workflow coverage job depends on lint and typecheck
Scenario: CI workflow coverage job depends on unit_tests
Given the CI workflow file exists
When I parse the coverage job from the CI workflow
Then the coverage job should depend on lint and typecheck
Then the coverage job should depend on unit_tests
Scenario: Coverage report session emits CI-parseable summary on success
Given the noxfile.py exists
@@ -186,17 +186,13 @@ def step_check_ci_coverage_nox(context: Any) -> None:
)
@then("the coverage job should depend on lint and typecheck")
@then("the coverage job should depend on unit_tests")
def step_check_ci_coverage_deps(context: Any) -> None:
job = context.ci_coverage_job
needs = job.get("needs", [])
if "lint" not in needs:
if "unit_tests" not in needs:
raise AssertionError(
f"CI coverage job does not depend on 'lint': needs={needs}"
)
if "typecheck" not in needs:
raise AssertionError(
f"CI coverage job does not depend on 'typecheck': needs={needs}"
f"CI coverage job does not depend on 'unit_tests': needs={needs}"
)