feat: new collections (#4530)
Co-authored-by: Peng Xiao <pengxiao@outlook.com>
This commit is contained in:
@@ -4,6 +4,7 @@ import {
|
||||
clickNewPageButton,
|
||||
clickPageMoreActions,
|
||||
getBlockSuiteEditorTitle,
|
||||
getPageOperationButton,
|
||||
waitForEditorLoad,
|
||||
} from '@affine-test/kit/utils/page-logic';
|
||||
import { expect } from '@playwright/test';
|
||||
@@ -18,9 +19,9 @@ test('New a page ,then open it and show delete modal', async ({
|
||||
await getBlockSuiteEditorTitle(page).click();
|
||||
await getBlockSuiteEditorTitle(page).fill('this is a new page to delete');
|
||||
await page.getByTestId('all-pages').click();
|
||||
const cell = page.getByRole('cell', {
|
||||
name: 'this is a new page to delete',
|
||||
});
|
||||
const cell = page
|
||||
.getByTestId('page-list-item')
|
||||
.getByText('this is a new page to delete');
|
||||
expect(cell).not.toBeUndefined();
|
||||
|
||||
await cell.click();
|
||||
@@ -50,11 +51,7 @@ test('New a page ,then go to all pages and show delete modal', async ({
|
||||
});
|
||||
expect(cell).not.toBeUndefined();
|
||||
|
||||
await page
|
||||
.getByTestId('more-actions-' + newPageId)
|
||||
.getByRole('button')
|
||||
.first()
|
||||
.click();
|
||||
await getPageOperationButton(page, newPageId).click();
|
||||
const deleteBtn = page.getByTestId('move-to-trash');
|
||||
await deleteBtn.click();
|
||||
const confirmTip = page.getByText('Delete page?');
|
||||
|
||||
Reference in New Issue
Block a user