test: wait for page to load
This commit is contained in:
@@ -12,10 +12,7 @@ test.describe('web console', () => {
|
|||||||
//Later on, call this function with some arguments.
|
//Later on, call this function with some arguments.
|
||||||
// const msg = await getEditoVersionHandle.evaluate((post, args) => post);
|
// const msg = await getEditoVersionHandle.evaluate((post, args) => post);
|
||||||
// console.log(getEditoVersionHandle);
|
// console.log(getEditoVersionHandle);
|
||||||
await page.waitForTimeout(500);
|
const editoVersion = await page.evaluate(() => window.__editoVersion);
|
||||||
const editoVersion = await page.evaluate(
|
|
||||||
() => (window as any).__editoVersion
|
|
||||||
);
|
|
||||||
// const documentEditorVersion = await page.inputValue('input#editor-version');
|
// const documentEditorVersion = await page.inputValue('input#editor-version');
|
||||||
const pkgEditorVersion = pkg.dependencies['@blocksuite/editor'];
|
const pkgEditorVersion = pkg.dependencies['@blocksuite/editor'];
|
||||||
|
|
||||||
|
|||||||
@@ -4,6 +4,6 @@ export function loadPage() {
|
|||||||
test.beforeEach(async ({ page }) => {
|
test.beforeEach(async ({ page }) => {
|
||||||
await page.goto('http://localhost:8080');
|
await page.goto('http://localhost:8080');
|
||||||
// waiting for page loading end
|
// waiting for page loading end
|
||||||
// await page.waitForTimeout(1000);
|
await page.waitForSelector('#__next');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user