Repository navigation
test: guarantee the logo-less member dialog case through the e2e overlay - #1149
Merged
Merged
Conversation
tests/e2e/member-directory.spec.js is the only browser coverage of MemberProfile's initials arm, and it chose the member driving that case by reading data/members.json off disk and skipping when every member carried a logo. That file is regenerated from the CNCF landscape, so the condition is upstream state: at 7ab301e only two of 101 members lack a logo, and a refresh that gives both of them one retires the case as a silent skip no gate reports. Read the members through loadSiteData() instead, as tests/e2e/data-fixtures.spec.js and tests/e2e/data-variants.spec.js already do. The committed overlay in tests/e2e/fixtures/data/members.json appends coverage-fixture-org with a null logo, so under E2E_COVERAGE=1 a logo-less member is a property of the build and its absence is asserted as a broken fixture rather than skipped. The plain end-to-end job applies no overlay and keeps the skip, because there the case really does depend on upstream data. 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 |
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
tests/e2e/member-directory.spec.jsholds the only browser coverage of themember profile dialog's logo-less arm
(
src/components/MemberDirectory/MemberProfile.js:35-41). It selected themember driving that case by reading
data/members.jsonoff disk andtest.skipping when every member carried a logo.That file is regenerated from the CNCF landscape by
npm run generate:members,so the condition is upstream state rather than a source edit: at
main=7ab301eonly two of 101 members lack a logo (DiDi,Subaru Corporation). A landscape refresh that gives both of them one retiresthe case as a skip — and no gate reports a skip, so a green suite would
stop covering a shipped UI arm without saying so.
This PR reads the members through
loadSiteData('members.json')fromtests/tools/e2e-data-fixtures.cjs, astests/e2e/data-fixtures.spec.jsandtests/e2e/data-variants.spec.jsalready do. The committed overlay intests/e2e/fixtures/data/members.jsonappendscoverage-fixture-orgwith"logo": null, so underE2E_COVERAGE=1a logo-less member is a property ofthe build; its absence is then asserted as a broken fixture rather than
skipped. The plain
End-to-end testsjob applies no overlay(
loadSiteDatareturns the file unchanged there) and keeps the existing skip,because in that job the case really does depend on upstream data.
No behaviour of the dialog is restated: the case still compares the dialog's
large initials against the card's server-rendered ones, and a real logo-less
member is still preferred when the data has one.
Verification
npm run test:unitat this head: 1966 passed, 0 failed (node v26.10.0,TZ=UTC).npx prettier --check tests/e2e/member-directory.spec.js: clean.npx playwright test --list tests/e2e/member-directory.spec.js: all sixcases enumerate.
7ab301e:loadSiteData('members.json', {})→ 101 members, 2 without a logo;loadSiteData('members.json', {E2E_COVERAGE: '1'})→ 102 members, 3 withouta logo, the third being
Coverage Fixture Organization.libglib-2.0.so.0and no root to install Playwright's system dependencies,so
chrome-headless-shellexits 127 before any spec runs. TheEnd-to-end coveragejob is the check that exercises it.Files claimed
tests/e2e/member-directory.spec.jsonly. Disjoint fromtests/e2e/fixtures/data-variants/members.json(#1104),tests/tools/e2e-data-fixtures.cjsandtests/e2e-data-fixtures.test.mjs(#1110, #1113),
tests/e2e/dialog-non-dismissing.spec.js(#1120), and everyworkflow file.
Related Issue
Closes #1148
— hive: agent=quality backend=copilot model=claude-opus-5 copilot=1.0.88