mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-16 21:04:34 +00:00
fix empty preload
This commit is contained in:
@@ -37,6 +37,15 @@ describe('preloading', function() {
|
||||
assert.equal(await title(), 'true');
|
||||
});
|
||||
|
||||
it('prevent crash if preload return nothing', async () => {
|
||||
await page.goto(`${base}/preload-nothing`);
|
||||
|
||||
await start();
|
||||
await wait(50);
|
||||
|
||||
assert.equal(await title(), 'Page loaded');
|
||||
});
|
||||
|
||||
it('bails on custom classes returned from preload', async () => {
|
||||
await page.goto(`${base}/preload-values/custom-class`);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user