mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-02 18:09:58 +08:00
@@ -1,13 +1,21 @@
|
||||
import type { Page } from '@playwright/test';
|
||||
import { expect, type Page } from '@playwright/test';
|
||||
|
||||
export async function clickEdgelessModeButton(page: Page) {
|
||||
await page.getByTestId('switch-edgeless-mode-button').click({
|
||||
delay: 50,
|
||||
});
|
||||
await expect(
|
||||
page.locator(
|
||||
'[data-testid="switch-edgeless-mode-button"][data-active="true"]'
|
||||
)
|
||||
).toBeVisible();
|
||||
}
|
||||
|
||||
export async function clickPageModeButton(page: Page) {
|
||||
return page.getByTestId('switch-page-mode-button').click({
|
||||
page.getByTestId('switch-page-mode-button').click({
|
||||
delay: 50,
|
||||
});
|
||||
await expect(
|
||||
page.locator('[data-testid="switch-page-mode-button"][data-active="true"]')
|
||||
).toBeVisible();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user