Uploaded image for project: 'Red Hat Advanced Cluster Security'
  1. Red Hat Advanced Cluster Security
  2. ROX-32572

[Layer Filtering] Fix E2E test selector mismatch for filter chip rendering

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • None
    • None
    • Rox Sprint 4.10G

      Overview:
      The Layer type filter E2E test is failing because it uses incorrect CSS selectors. The test looks for .pf-v5-c-chip-group (ChipGroup) but the CompoundSearchFilterLabels component renders filters using PatternFly's LabelGroup (.pf-v5-c-label-group).

      Root Cause:

      • Test uses selectors.filterChipGroupForCategory() which targets .pf-v5-c-chip-group
      • Actual component CompoundSearchFilterLabels.tsx uses [LabelGroup] which renders as .pf-v5-c-label-group
      • The selectors file already has both filterChipGroup_ and filterLabelGroup_ selectors available

      Implementation Details:
      Update the test to use the correct LabelGroup selectors instead of ChipGroup selectors.

      Acceptance Criteria:

      • [ ] Update test to use filterLabelGroupForCategory instead of filterChipGroupForCategory
      • [ ] Update test to use filterLabelGroupItem instead of filterChipGroupItem
      • [ ] E2E test should apply Layer type filter correctly passes

      Files to Update:
      1. ui/apps/platform/cypress/integration/vulnerabilities/workloadCves/workloadCveOverviewPage.test.ts:359-364 - Change selector calls from filterChipGroup_ to filterLabelGroup_

      Related Tickets:

      • ROX-32569 - Parent ticket for the Layer Filtering fix that triggered this test failure

              schaudhr Saif Chaudhry
              schaudhr Saif Chaudhry
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: