From e9043735ac47973d0bf9f597c61b1ca756be33a7 Mon Sep 17 00:00:00 2001 From: Juanjo Fernandez Date: Mon, 8 Jul 2024 14:57:04 +0200 Subject: [PATCH] LPD-30600 - SF --- .../helpers/DataSetManagerApiHelpers.ts | 2 +- .../pages/FDSFragmentPage.ts | 27 ++++++++++++++----- 2 files changed, 21 insertions(+), 8 deletions(-) diff --git a/modules/test/playwright/tests/frontend-data-set-admin-web/helpers/DataSetManagerApiHelpers.ts b/modules/test/playwright/tests/frontend-data-set-admin-web/helpers/DataSetManagerApiHelpers.ts index e6195eb4e3fffc..91eb1e1eae74cb 100644 --- a/modules/test/playwright/tests/frontend-data-set-admin-web/helpers/DataSetManagerApiHelpers.ts +++ b/modules/test/playwright/tests/frontend-data-set-admin-web/helpers/DataSetManagerApiHelpers.ts @@ -404,7 +404,7 @@ export class DataSetManagerApiHelpers extends ApiHelpers { itemLabel, label_i18n, multiple, - preselectedValues + preselectedValues, }; return this.patch(url, data); diff --git a/modules/test/playwright/tests/frontend-data-set-admin-web/tests/data-set-fragment/pages/FDSFragmentPage.ts b/modules/test/playwright/tests/frontend-data-set-admin-web/tests/data-set-fragment/pages/FDSFragmentPage.ts index 754c3a71c5ecff..c58eefe001107b 100644 --- a/modules/test/playwright/tests/frontend-data-set-admin-web/tests/data-set-fragment/pages/FDSFragmentPage.ts +++ b/modules/test/playwright/tests/frontend-data-set-admin-web/tests/data-set-fragment/pages/FDSFragmentPage.ts @@ -35,16 +35,25 @@ export class FDSFragmentPage { this.creationMenuButton = page.getByRole('button', {name: 'New'}); this.emptyStateTitle = page.getByText('No Results Found'); this.fdsActiveViewSelector = page.getByLabel('Show View Options'); - this.fdsAddFilterButton = page.getByRole('button', {exact: true, name: 'Add Filter'}); + this.fdsAddFilterButton = page.getByRole('button', { + exact: true, + name: 'Add Filter', + }); this.fdsCardsWrapper = page.locator('.cards-container'); - this.fdsFilterButton = page.getByRole('button', {exact: true, name: 'Filter'}); + this.fdsFilterButton = page.getByRole('button', { + exact: true, + name: 'Filter', + }); this.fdsFilterResumeButton = page.locator('.filter-resume'); this.fdsListWrapper = page.locator('.list-sheet'); this.fdsPaginationWrapper = page.locator( '.data-set-pagination-wrapper' ); this.fdsPaginationResults = page.locator('.pagination-results'); - this.fdsResetFilterButton = page.getByRole('button', {exact: true, name:'Reset Filters'}); + this.fdsResetFilterButton = page.getByRole('button', { + exact: true, + name: 'Reset Filters', + }); this.fdsTableWrapper = page.locator('.dnd-table'); this.fragmentWidgetSearchInput = page.getByLabel( 'Search Fragments and Widgets' @@ -66,11 +75,15 @@ export class FDSFragmentPage { node.getAttribute('aria-controls') ); await this.fdsFilterButton.click(); - await this.page.locator(`#${filterDropdownId}`).waitFor({state: 'visible'}); + await this.page + .locator(`#${filterDropdownId}`) + .waitFor({state: 'visible'}); this.fdsFilterItem = this.page.locator(`#${filterDropdownId}`); - this.fdsFilterItem.getByRole('menuitem', { - name: filterLabel - }).click(); + this.fdsFilterItem + .getByRole('menuitem', { + name: filterLabel, + }) + .click(); } async changeVisualizationMode(visualizationMode: VisualizationMode) {