Skip to content

Commit

Permalink
[RFR] Update selectFilter() function (#1307)
Browse files Browse the repository at this point in the history
* Update selectFilter() function

Signed-off-by: Nandini Chandra <[email protected]>

* Update selectFilter() function

Signed-off-by: Nandini Chandra <[email protected]>

---------

Signed-off-by: Nandini Chandra <[email protected]>
  • Loading branch information
nachandr authored Jan 17, 2025
1 parent 04a955e commit a58bce5
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions cypress/utils/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ import {
expandRow,
filterDropDownContainer,
filterInput,
filterToggleButton,
firstPageButton,
itemsPerPageMenuOptions,
itemsPerPageToggleButton,
Expand Down Expand Up @@ -393,13 +392,9 @@ export function notExists(value: string, tableSelector = appTable): void {
});
}

export function selectFilter(filterName: string, identifiedRisk?: boolean, value = 0): void {
cy.get(filterToggleButton)
.eq(value)
.within(() => {
click("#filtered-by");
clickWithinByText('div[class="pf-v5-c-menu__content"]', "button", filterName);
});
export function selectFilter(filterName: string): void {
cy.get("#filtered-by").click();
clickWithinByText('div[class="pf-v5-c-menu__content"]', "button", filterName);
}

export function filterInputText(searchTextValue: string, value: number): void {
Expand Down

0 comments on commit a58bce5

Please sign in to comment.