|
|
@ -118,7 +118,7 @@ export class SelectOptionCellPageObject extends BasePage { |
|
|
|
index, |
|
|
|
index, |
|
|
|
columnHeader, |
|
|
|
columnHeader, |
|
|
|
option, |
|
|
|
option, |
|
|
|
multiSelect, |
|
|
|
multiSelect = false, |
|
|
|
}: { |
|
|
|
}: { |
|
|
|
index: number; |
|
|
|
index: number; |
|
|
|
columnHeader: string; |
|
|
|
columnHeader: string; |
|
|
@ -134,10 +134,18 @@ export class SelectOptionCellPageObject extends BasePage { |
|
|
|
|
|
|
|
|
|
|
|
await selectCell.locator('.ant-select-selection-search-input').type(option); |
|
|
|
await selectCell.locator('.ant-select-selection-search-input').type(option); |
|
|
|
|
|
|
|
|
|
|
|
await selectCell.locator('.ant-select-selection-search-input').press('Enter'); |
|
|
|
// await selectCell.locator('.ant-select-selection-search-input').press('Enter');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Wait for update api call
|
|
|
|
|
|
|
|
const saveRowAction = () => selectCell.locator('.ant-select-selection-search-input').press('Enter'); |
|
|
|
|
|
|
|
await this.waitForResponse({ |
|
|
|
|
|
|
|
uiAction: saveRowAction, |
|
|
|
|
|
|
|
requestUrlPathToMatch: 'api/v1/db/data/noco/', |
|
|
|
|
|
|
|
httpMethodsToMatch: ['PATCH'], |
|
|
|
|
|
|
|
responseJsonMatcher: resJson => String(resJson?.[columnHeader]).includes(String(option)), |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
if (multiSelect) await selectCell.locator('.ant-select-selection-search-input').press('Escape'); |
|
|
|
if (multiSelect) await selectCell.locator('.ant-select-selection-search-input').press('Escape'); |
|
|
|
// todo: wait for update api call
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
async verifySelectedOptions({ |
|
|
|
async verifySelectedOptions({ |
|
|
|