mirror of
https://github.com/hcengineering/platform.git
synced 2026-08-17 18:05:42 +02:00
feat: hide inactive employees (#10821)
Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
This commit is contained in:
@@ -84,7 +84,8 @@ test.describe('contact tests', () => {
|
||||
await contractPage.clickCreateButton()
|
||||
await contractPage.waitForFormAntiCardDetached()
|
||||
await contractPage.kickEmployee(first, last)
|
||||
// In non refactored code, the last assert just checks if the employee does exist, not if it has inactive status
|
||||
// After kick, employee is inactive and hidden by default. Toggle off to see it.
|
||||
await contractPage.toggleHideInactive()
|
||||
await contractPage.expectKickEmployeeShowsInactiveStatus(first, last)
|
||||
})
|
||||
|
||||
|
||||
@@ -209,6 +209,12 @@ export class ContractPage {
|
||||
}
|
||||
}
|
||||
|
||||
async toggleHideInactive (): Promise<void> {
|
||||
await this.page.locator('[data-id="btn-viewOptions"]').click()
|
||||
await this.page.locator('.antiCard-menu__item', { hasText: 'Hide inactive' }).click()
|
||||
await this.page.keyboard.press('Escape')
|
||||
}
|
||||
|
||||
// ASSERTIONS
|
||||
|
||||
async expectKickEmployeeShowsInactiveStatus (first: string, last: string): Promise<void> {
|
||||
|
||||
Reference in New Issue
Block a user