Blueprints: Add test ids

This updates the data-testid of Create button in the header (`Link` component, not OUIA-compliant) and adds a data-testid to the blueprint search input (`SearchInput` component, also not OUIA-compliant).

A testId was also added to the blueprint actions dropdown (`MenuToggle`).
This commit is contained in:
regexowl 2024-03-28 11:14:59 +01:00 committed by Klara Simickova
parent 835920a555
commit 4a74813c2b
3 changed files with 3 additions and 1 deletions

View file

@ -45,6 +45,7 @@ export const BlueprintActionsMenu: React.FunctionComponent<
onClick={() => setShowBlueprintActionsMenu(!showBlueprintActionsMenu)}
variant="plain"
aria-label="blueprint menu toggle"
data-testid="blueprint-action-menu-toggle"
isDisabled={selectedBlueprintId === undefined}
>
<EllipsisVIcon aria-hidden="true" />

View file

@ -167,6 +167,7 @@ const BlueprintSearch = ({ blueprintsTotal }: blueprintSearchProps) => {
onChange={(_event, value) => onChange(value)}
onClear={() => onChange('')}
resultsCount={`${blueprintsTotal} blueprints`}
data-testid="blueprints-search-input"
/>
);
};

View file

@ -99,7 +99,7 @@ export const ImageBuilderHeader = ({
<Link
to={resolveRelPath('imagewizard')}
className="pf-c-button pf-m-tertiary"
data-testid="create-image-action"
data-testid="blueprints-create-button"
>
Create
</Link>