Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | 1x 1x 1x 1x 1x 1x 1x 2x 2x 1x 1x 1x 1x 1x 1x | import type { Locator, Page } from '@playwright/test';
/** Page-object a toast / snackbar notifikáció-hoz. */
export class DyE2E_ToastPageObject {
constructor(private readonly page: Page) {}
get root(): Locator {
return this.page.locator('.mat-mdc-snack-bar-container, dynamo-toast, [role="status"]').first();
}
async waitForToast(timeout: number = 5_000): Promise<string> {
await this.root.waitFor({ state: 'visible', timeout });
return (await this.root.textContent()) ?? '';
}
}
|