diff --git a/cypress/e2e/po/components/sortable-table.po.ts b/cypress/e2e/po/components/sortable-table.po.ts index 5f59b1849b4..0e3f77ad2bf 100644 --- a/cypress/e2e/po/components/sortable-table.po.ts +++ b/cypress/e2e/po/components/sortable-table.po.ts @@ -80,11 +80,17 @@ export default class SortableTablePo extends ComponentPo { * @param searchText * @returns */ - filter(searchText: string) { - return this.filterComponent() + filter(searchText: string, checkQuery = false) { + const res = this.filterComponent() .focus() .clear() .type(searchText); + + if (checkQuery) { + cy.url().should('include', `q=${ searchText }`); + } + + return res; } resetFilter() { diff --git a/cypress/e2e/po/pages/explorer/config-map.po.ts b/cypress/e2e/po/pages/explorer/config-map.po.ts index 60459d0536d..6204f51e63f 100644 --- a/cypress/e2e/po/pages/explorer/config-map.po.ts +++ b/cypress/e2e/po/pages/explorer/config-map.po.ts @@ -39,7 +39,7 @@ export class ConfigMapPagePo extends PagePo { } searchForConfigMap(name: string) { - return this.list().resourceTable().sortableTable().filter(name); + return this.list().resourceTable().sortableTable().filter(name, true); } title() { diff --git a/cypress/e2e/po/pages/explorer/network-policy.po.ts b/cypress/e2e/po/pages/explorer/network-policy.po.ts index ad229c9d6ab..77999c094af 100644 --- a/cypress/e2e/po/pages/explorer/network-policy.po.ts +++ b/cypress/e2e/po/pages/explorer/network-policy.po.ts @@ -39,6 +39,6 @@ export class NetworkPolicyPagePo extends PagePo { } searchForNetworkPolicy(name: string) { - return this.list().resourceTable().sortableTable().filter(name); + return this.list().resourceTable().sortableTable().filter(name, true); } }