fix(test): AUT for ExploreSortOrder (#23389)

* fix exploreSortOrder test

* minor fix
This commit is contained in:
Pranita Fulsundar 2025-09-15 15:57:09 +05:30 committed by GitHub
parent 7325435030
commit 6e29d1b87e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -10,7 +10,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
import { test } from '@playwright/test'; import { expect, test } from '@playwright/test';
import { DATA_ASSETS_SORT } from '../../constant/explore'; import { DATA_ASSETS_SORT } from '../../constant/explore';
import { SidebarItem } from '../../constant/sidebar'; import { SidebarItem } from '../../constant/sidebar';
import { EntityDataClass } from '../../support/entity/EntityDataClass'; import { EntityDataClass } from '../../support/entity/EntityDataClass';
@ -95,25 +95,14 @@ test.describe('Explore Sort Order Filter', () => {
await page.getByTestId('update-btn').click(); await page.getByTestId('update-btn').click();
await selectSortOrder(page, 'Name'); await selectSortOrder(page, 'Name');
await page.waitForLoadState('networkidle');
await verifyEntitiesAreSorted(page); await verifyEntitiesAreSorted(page);
await page.getByTestId('search-dropdown-Data Assets').click(); const clearFilters = page.getByTestId('clear-filters');
await page.waitForSelector( expect(clearFilters).toBeVisible();
'[data-testid="drop-down-menu"] [data-testid="loader"]',
{
state: 'detached',
}
);
await page.waitForSelector( await clearFilters.click();
`[data-testid="${filter.toLowerCase()}-checkbox"]`,
{
state: 'visible',
}
);
await page.getByTestId(`${filter.toLowerCase()}-checkbox`).uncheck();
await page.getByTestId('update-btn').click();
await afterAction(); await afterAction();
}); });