Repository navigation
test: cover CommunityPeople's unknown-section roster fallback end to end - #1136
Merged
Merged
Conversation
src/components/CommunityPeople/index.js line 134 resolves its roster with `peopleData.people[section] || []`. The published site renders the component only with section="tab" and section="staff", and tests/community-people-data.test.mjs fails the build when a section rendered under docs/ is absent from data/community-people.json or carries no entries, so no published page can take the fallback. A data overlay cannot reach it either: emptying a section hands the component an array off the object rather than the fallback, which runs only when the key is absent. Add a fixture page under the E2E_COVERAGE-only e2e-coverage-fixtures docs instance rendering an undefined section, and a spec pairing the published TAB page with it: a populated grid on the first, a grid with zero cards on the second. Closes #1135 Signed-off-by: quality <quality@hive.kubestellar.io>
Contributor
Author
|
Important Held for human review by the hive's ACMM level gate. This PR was opened by the "quality" agent while Hive policy required a human checkpoint for that agent. Non-outreach agents are held at ACMM L3–L5; the Hive will keep the |
mrbobbytables
deleted the
quality/test-community-people-unknown-section
branch
October 7, 2026 15:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Test Improvement
src/components/CommunityPeople/index.jsline 134 resolves its roster withpeopleData.people[section] || [], and nothing in a browser has ever taken theright operand.
The published site renders the component from exactly two documents —
docs/community/technical-advisory-board.md:29(section="tab") anddocs/community/index.md:133(section="staff") — andtests/community-people-data.test.mjs:92-104fails the build when a sectionrendered under
docs/is missing fromdata/community-people.jsonor carriesno entries. The fallback is therefore unreachable from published content by
construction. A data overlay cannot reach it either: emptying a section hands
the component an array straight off the object, while the
|| []arm runs onlywhen the key is absent.
So the shape gets a page of its own, following
tests/e2e/fixtures/docs/cncf-project-card.mdx:tests/e2e/fixtures/docs/community-people.mdx(new) renders<CommunityPeople section="coverage-fixture-no-such-section" />.docusaurus.config.js:86-102registers thee2e-coverage-fixturesdocsinstance only when
E2E_COVERAGE=1, sonpm run build:production, thegating "End-to-end tests" job and the deployed site never compile it.
sectionsReferencedByDocs()walksdocs/only(
tests/community-people-data.test.mjs:48), so the undefined section doesnot trip the contract above.
tests/e2e/community-people-unknown-section.spec.js(new) asserts thegrid from both ends: the published TAB page produces one grid with more than
zero cards, and the fixture route produces one grid with zero. An empty grid
on its own would also be produced by a selector that matched nothing, which
is why the populated case comes first.
Evidence
npm run test:unit:coverage(node v26.10.0,TZ=UTC) atmain=7ab301e: this file reports 100.00% lines / 100.00%regions, and
tests/community-people.test.mjs:160drives the arm directly.e2e-coverage, id11383321728, run37395255849,
job
End-to-end coverageat7ab301e:src/components/CommunityPeople/index.js | 100.00 | 87.10 | | 32 125 134.7ab301eagainstnpm run build:e2e:coverage:site: a coverage run containing the fixture casealone reports region 134 absent from this file's uncovered list.
npm test(check + 1966 unit tests) passes on this branch.What this does not do
Region 134 stays on the report's uncovered list in a run that also visits the
published page — the two instances' copies of the chunk map back to different
original coordinates, and
getRegionCoverageintests/tools/e2e-coverage-report.mjskeys a region on its exact coordinates.That is the attribution problem tracked in #1066 and #1079, the same limit
#1097 recorded for
RadarReports; it is not something a fixture can reach.Scope and coordination
This PR claims region 134 only of that row. Region 32 (the backdrop
onMouseDownarm) belongs to #1120 and region 125 (theonClosearrow) to the#1079 class; neither is touched.
Two new files, zero edits. It does not touch
tests/e2e/fixtures/docs/cncf-project-card.mdxortests/e2e/cncf-project-card.spec.js(#1124),tests/e2e/dialog-non-dismissing.spec.js(#1120),tests/e2e-data-fixtures.test.mjs(#1110, #1113),tests/tools/e2e-data-fixtures.cjs(#1110), or anything undertests/e2e/fixtures/data/ortests/e2e/fixtures/data-variants/. No workflowfile is involved.
Related Issue
Closes #1135
Human review required.
— hive: agent=quality backend=copilot model=claude-opus-5 copilot=1.0.88