Skip to content

Commit f79a529

Browse files
committed
ci: enforce coverage quality gates
Signed-off-by: Pouyanpi <13303554+Pouyanpi@users.noreply.github.com>
1 parent f4c1bc2 commit f79a529

2 files changed

Lines changed: 7 additions & 3 deletions

File tree

.github/codecov.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,19 @@ coverage:
22
status:
33
project:
44
default:
5-
informational: true
5+
target: auto
6+
threshold: 0.25%
7+
informational: false
68
patch:
79
default:
10+
target: 90%
11+
threshold: 0%
812
informational: true
913

1014
comment:
1115
layout: " diff, flags, files"
1216
behavior: default
13-
require_changes: false # if true: only post the comment if coverage changes
17+
require_changes: "coverage_drop OR uncovered_patch"
1418
require_base: false # [true :: must have a base report to post]
1519
require_head: true # [true :: must have a head report to post]
1620
hide_project_coverage: false # [true :: only show coverage on the git diff aka patch coverage]

.github/workflows/_test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ jobs:
7777
# Enable the langchain-community provider drift canary only when
7878
# testing upgraded dependencies (the scheduled latest-deps job).
7979
LANGCHAIN_PROVIDER_DRIFT_CHECK: ${{ inputs.upgrade-deps && '1' || '' }}
80-
run: make test-coverage
80+
run: make test-coverage ARGS="--cov-fail-under=85 --cov-report=term"
8181

8282
- name: Run pytest without coverage
8383
if: inputs.with-coverage == false

0 commit comments

Comments
 (0)