Report never-imported files in one coverage group only (#185684)

This commit is contained in:
Erwin Douna
2026-10-10 17:28:28 -04:00
committed by GitHub
parent 2c02f33cec
commit 648d303d16
2 changed files with 12 additions and 2 deletions
+7 -1
View File
@@ -934,7 +934,13 @@ jobs:
set -o pipefail
cov_params=()
if [[ "${SKIP_COVERAGE}" != "true" ]]; then
cov_params+=(--cov="homeassistant")
if [[ "${TEST_GROUP}" == "1" ]]; then
# Also report never-imported files as 0%. Listing every file
# is slow, so only one group does it.
cov_params+=(--cov="homeassistant")
else
cov_params+=(--cov)
fi
cov_params+=(--cov-report=xml)
cov_params+=(--junitxml=junit.xml -o junit_family=legacy)
fi
+5 -1
View File
@@ -626,7 +626,11 @@ filterwarnings = [
]
[tool.coverage.run]
source = ["homeassistant"]
# Measure only imported files; pass --cov=homeassistant to also report
# never-imported files as 0% (one CI bucket does that).
include = ["homeassistant/*"]
# --cov=<package> sets source, which overrides include on purpose
disable_warnings = ["include-ignored"]
[tool.coverage.report]
exclude_lines = [