mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-21 20:16:26 +08:00
feat: add change log (#1734)
Co-authored-by: Himself65 <himself65@outlook.com>
This commit is contained in:
@@ -29,3 +29,31 @@ test.describe('Open AFFiNE', () => {
|
||||
expect(currentWorkspaceName).toEqual('New Workspace 2');
|
||||
});
|
||||
});
|
||||
|
||||
test.describe('AFFiNE change log', () => {
|
||||
test('Open affine in first time after updated', async ({ page }) => {
|
||||
await openHomePage(page);
|
||||
const changeLogItem = page.locator('[data-testid=change-log]');
|
||||
await expect(changeLogItem).toBeVisible();
|
||||
const closeButton = page.locator('[data-testid=change-log-close-button]');
|
||||
await closeButton.click();
|
||||
await expect(changeLogItem).not.toBeVisible();
|
||||
await page.goto('http://localhost:8080');
|
||||
const currentChangeLogItem = page.locator('[data-testid=change-log]');
|
||||
await expect(currentChangeLogItem).not.toBeVisible();
|
||||
});
|
||||
test('Click right-bottom corner change log icon', async ({ page }) => {
|
||||
await openHomePage(page);
|
||||
await waitMarkdownImported(page);
|
||||
await page.locator('[data-testid=help-island]').click();
|
||||
const editorRightBottomChangeLog = page.locator(
|
||||
'[data-testid=right-bottom-change-log-icon]'
|
||||
);
|
||||
expect(await editorRightBottomChangeLog.isVisible()).toEqual(true);
|
||||
await page.getByRole('link', { name: 'All pages' }).click();
|
||||
const normalRightBottomChangeLog = page.locator(
|
||||
'[data-testid=right-bottom-change-log-icon]'
|
||||
);
|
||||
expect(await normalRightBottomChangeLog.isVisible()).toEqual(true);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -186,4 +186,22 @@ test.describe('Novice guidance for quick search', () => {
|
||||
await page.locator('[data-testid=quick-search-got-it]').click();
|
||||
await expect(quickSearchTips).not.toBeVisible();
|
||||
});
|
||||
test('After appearing once, it will not appear a second time', async ({
|
||||
page,
|
||||
}) => {
|
||||
await openHomePage(page);
|
||||
await waitMarkdownImported(page);
|
||||
const quickSearchTips = page.locator('[data-testid=quick-search-tips]');
|
||||
await expect(quickSearchTips).not.toBeVisible();
|
||||
await page.getByTestId('sliderBar-arrowButton-collapse').click();
|
||||
const sliderBarArea = page.getByTestId('sliderBar');
|
||||
await expect(sliderBarArea).not.toBeVisible();
|
||||
await expect(quickSearchTips).toBeVisible();
|
||||
await page.locator('[data-testid=quick-search-got-it]').click();
|
||||
await expect(quickSearchTips).not.toBeVisible();
|
||||
await page.reload();
|
||||
await page.locator('[data-testid=sliderBar-arrowButton-expand]').click();
|
||||
await page.getByTestId('sliderBar-arrowButton-collapse').click();
|
||||
await expect(quickSearchTips).not.toBeVisible();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user