mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-13 04:48:53 +00:00
fix(storybook): fix test (#5325)
<img width="440" alt="image" src="https://github.com/toeverything/AFFiNE/assets/102217452/329f9c12-cc0b-4aae-9352-3811ab0a27a6">
This commit is contained in:
@@ -16,7 +16,7 @@ export async function waitForAllPagesLoad(page: Page) {
|
||||
|
||||
export async function clickNewPageButton(page: Page) {
|
||||
// fixme(himself65): if too fast, the page will crash
|
||||
await page.getByTestId('new-page-button').first().click({
|
||||
await page.getByTestId('sidebar-new-page-button').click({
|
||||
delay: 100,
|
||||
});
|
||||
await waitForEditorLoad(page);
|
||||
|
||||
@@ -13,5 +13,5 @@ export async function clickSideBarCurrentWorkspaceBanner(page: Page) {
|
||||
}
|
||||
|
||||
export async function clickNewPageButton(page: Page) {
|
||||
return page.getByTestId('new-page-button').click();
|
||||
return page.getByTestId('sidebar-new-page-button').click();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user