mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-16 04:44:35 +00:00
handle tag click from another page
This commit is contained in:
@@ -59,4 +59,15 @@ describe('scroll', function() {
|
||||
|
||||
assert.ok(scrollY > 0);
|
||||
});
|
||||
|
||||
it('scrolls into a deeplink on a new page', async () => {
|
||||
await page.goto(`${base}/tall-page#foo`);
|
||||
await start();
|
||||
await prefetchRoutes();
|
||||
|
||||
await page.click('[href="another-tall-page#bar"]');
|
||||
await wait(50);
|
||||
const scrollY = await page.evaluate(() => window.scrollY);
|
||||
assert.ok(scrollY > 0);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user