-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCompleteStep.ts
More file actions
46 lines (35 loc) · 1.01 KB
/
CompleteStep.ts
File metadata and controls
46 lines (35 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import { expect, Page } from '@playwright/test';
import BasePageModel from '@/pages/BasePageModel';
import CompletePutawayTable from '../components/CompletePutawayTable';
class CompleteStep extends BasePageModel {
table: CompletePutawayTable;
constructor(page: Page) {
super(page);
this.table = new CompletePutawayTable(page);
}
async isLoaded() {
await expect(this.table.table).toBeVisible();
}
get completePutawayButton() {
return this.page.getByTestId('complete-putaway-button').nth(1);
}
get confirmPutawayDialog() {
return this.page.locator('.react-confirm-alert');
}
get yesButtonOnConfirmPutawayDialog() {
return this.confirmPutawayDialog.getByRole('button', {
name: 'Yes',
exact: true,
});
}
get noButtonOnConfirmPutawayDialog() {
return this.confirmPutawayDialog.getByRole('button', {
name: 'No',
exact: true,
});
}
get editButton() {
return this.page.getByTestId('edit-button').first();
}
}
export default CompleteStep;