mirror of
https://github.com/actualbudget/actual.git
synced 2026-04-30 10:14:53 -05:00
28 lines
683 B
JavaScript
28 lines
683 B
JavaScript
export class ReportsPage {
|
|
constructor(page) {
|
|
this.page = page;
|
|
this.pageContent = page.getByTestId('reports-page');
|
|
}
|
|
|
|
async waitToLoad() {
|
|
return this.pageContent.getByRole('button', { name: /^Net/ }).waitFor();
|
|
}
|
|
|
|
async goToNetWorthPage() {
|
|
await this.pageContent.getByRole('button', { name: /^Net/ }).click();
|
|
return new ReportsPage(this.page);
|
|
}
|
|
|
|
async goToCashFlowPage() {
|
|
await this.pageContent.getByRole('button', { name: /^Cash/ }).click();
|
|
return new ReportsPage(this.page);
|
|
}
|
|
|
|
async getAvailableReportList() {
|
|
return this.pageContent
|
|
.getByRole('button')
|
|
.getByRole('heading')
|
|
.allTextContents();
|
|
}
|
|
}
|