Merge branch 'feat/desktop-profile-page-tags' into chore/reconcile-ui-review
This commit is contained in:
@@ -50,6 +50,33 @@ test('Profile link in nav for authed users; landing shows counts', async ({ page
|
||||
await expect(page.getByTestId('overview-collections')).toBeVisible();
|
||||
});
|
||||
|
||||
test('Page tags tab reaches the page-tags list on desktop', async ({ page }) => {
|
||||
// Page tags are a first-class Library section on mobile; desktop reaches
|
||||
// them through this profile tab.
|
||||
await stubAuthenticated(page);
|
||||
await page.route('**/api/v1/me/page-tags?*', (route) =>
|
||||
route.fulfill({
|
||||
status: 200,
|
||||
contentType: 'application/json',
|
||||
body: JSON.stringify({ items: [], page: { limit: 100, offset: 0, total: 0 } })
|
||||
})
|
||||
);
|
||||
// Registered after the general route so distinct URLs resolve here.
|
||||
await page.route('**/api/v1/me/page-tags/distinct*', (route) =>
|
||||
route.fulfill({
|
||||
status: 200,
|
||||
contentType: 'application/json',
|
||||
body: JSON.stringify({ items: [] })
|
||||
})
|
||||
);
|
||||
|
||||
await page.goto('/profile');
|
||||
await expect(page.getByTestId('tab-page-tags')).toBeVisible();
|
||||
await page.getByTestId('tab-page-tags').click();
|
||||
await expect(page).toHaveURL(/\/profile\/page-tags$/);
|
||||
await expect(page.getByTestId('library-page-tags-empty')).toBeVisible();
|
||||
});
|
||||
|
||||
test('Account tab reaches the password form', async ({ page }) => {
|
||||
await stubAuthenticated(page);
|
||||
await page.goto('/profile');
|
||||
|
||||
Reference in New Issue
Block a user