Browse Source

test: tool bar sort typo bug

Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
pull/5106/head
Raju Udava 2 years ago
parent
commit
2a302893dc
  1. 11
      tests/playwright/pages/Dashboard/common/Toolbar/Sort.ts
  2. 1
      tests/playwright/tests/columnCheckbox.spec.ts

11
tests/playwright/pages/Dashboard/common/Toolbar/Sort.ts

@ -35,7 +35,16 @@ export class ToolbarSortPage extends BasePage {
await this.get().locator(`button:has-text("Add Sort Option")`).click();
await this.rootPage.locator('.nc-sort-field-select').last().click();
// read content of the dropdown
const col = await this.rootPage.locator('.nc-sort-field-select').textContent();
if (col !== columnTitle) {
await this.rootPage.locator('.nc-sort-field-select').last().click();
await this.rootPage
.locator('div.ant-select-dropdown.nc-dropdown-toolbar-field-list')
.locator(`div[label="${columnTitle}"]`)
.last()
.click();
}
// network request will be triggered only after dir-select is clicked
//

1
tests/playwright/tests/columnCheckbox.spec.ts

@ -26,6 +26,7 @@ test.describe('Checkbox - cell, filter, sort', () => {
opType: param.opType,
value: param.value,
isLocallySaved: false,
dataType: 'Checkbox',
});
await toolbar.clickFilter();

Loading…
Cancel
Save