mirror of
https://github.com/nocodb/nocodb.git
synced 2026-04-25 06:25:29 +00:00
fix(test): user select field test fail issue
This commit is contained in:
@@ -51,7 +51,7 @@ export class UserOptionColumnPageObject extends BasePage {
|
||||
const selector = this.column.get().locator('.nc-user-select >> .ant-select-selector');
|
||||
await selector.click();
|
||||
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'visible' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'visible' });
|
||||
|
||||
if (multiSelect) {
|
||||
const optionsToSelect = Array.isArray(option) ? option : [option];
|
||||
@@ -66,7 +66,7 @@ export class UserOptionColumnPageObject extends BasePage {
|
||||
await this.selectOption({ option });
|
||||
}
|
||||
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'hidden' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'hidden' });
|
||||
|
||||
await this.column.save({ isUpdated: true });
|
||||
}
|
||||
@@ -94,7 +94,7 @@ export class UserOptionColumnPageObject extends BasePage {
|
||||
|
||||
await this.column.get().locator('.nc-default-value-wrapper > .relative > .nc-cell-user').click();
|
||||
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'visible' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'visible' });
|
||||
|
||||
expect(await this.rootPage.getByTestId(`select-option-${columnTitle}-undefined`).count()).toEqual(totalCount);
|
||||
await this.column.get().locator('.nc-cell-user').click();
|
||||
|
||||
@@ -37,7 +37,7 @@ export class UserOptionCellPageObject extends BasePage {
|
||||
|
||||
await selectCell.click();
|
||||
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'visible' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'visible' });
|
||||
|
||||
if (index === -1) {
|
||||
const selectOption = this.rootPage.getByTestId(`select-option-${columnHeader}-undefined`).getByText(option);
|
||||
@@ -54,7 +54,7 @@ export class UserOptionCellPageObject extends BasePage {
|
||||
await this.rootPage.keyboard.press('Escape');
|
||||
}
|
||||
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'hidden' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'hidden' });
|
||||
}
|
||||
|
||||
async clear({ index, columnHeader, multiSelect }: { index: number; columnHeader: string; multiSelect?: boolean }) {
|
||||
@@ -81,7 +81,7 @@ export class UserOptionCellPageObject extends BasePage {
|
||||
|
||||
// Press `Escape` to close the dropdown
|
||||
await this.rootPage.keyboard.press('Escape');
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell').waitFor({ state: 'hidden' });
|
||||
await this.rootPage.locator('.nc-dropdown-user-select-cell.active').waitFor({ state: 'hidden' });
|
||||
}
|
||||
|
||||
async verify({
|
||||
|
||||
Reference in New Issue
Block a user