diff --git a/examples/cookies.js b/examples/cookies.js index 34081ba25..d4a9ac3d6 100644 --- a/examples/cookies.js +++ b/examples/cookies.js @@ -18,7 +18,7 @@ export const options = { }; export default async function () { - const page = browser.newPage(); + const page = await browser.newPage(); const context = page.context(); try { diff --git a/examples/keyboard.js b/examples/keyboard.js index 80da5168a..37a5787a1 100644 --- a/examples/keyboard.js +++ b/examples/keyboard.js @@ -14,7 +14,7 @@ export const options = { } export default async function () { - const page = browser.newPage(); + const page = await browser.newPage(); await page.goto('https://test.k6.io/my_messages.php', { waitUntil: 'networkidle' }); diff --git a/examples/mouse.js b/examples/mouse.js index 045e73fa9..23cc3ebb7 100644 --- a/examples/mouse.js +++ b/examples/mouse.js @@ -14,7 +14,7 @@ export const options = { } export default async function () { - const page = browser.newPage(); + const page = await browser.newPage(); await page.goto('https://test.k6.io/', { waitUntil: 'networkidle' }); diff --git a/examples/multiple-scenario.js b/examples/multiple-scenario.js index ab48a9e50..24828c526 100644 --- a/examples/multiple-scenario.js +++ b/examples/multiple-scenario.js @@ -33,7 +33,7 @@ export const options = { } export async function messages() { - const page = browser.newPage(); + const page = await browser.newPage(); try { await page.goto('https://test.k6.io/my_messages.php', { waitUntil: 'networkidle' }); @@ -43,7 +43,7 @@ export async function messages() { } export async function news() { - const page = browser.newPage(); + const page = await browser.newPage(); try { await page.goto('https://test.k6.io/news.php', { waitUntil: 'networkidle' }); diff --git a/examples/pageon.js b/examples/pageon.js index 77c2bdeff..12254dd79 100644 --- a/examples/pageon.js +++ b/examples/pageon.js @@ -18,7 +18,7 @@ export const options = { } export default async function() { - const page = browser.newPage(); + const page = await browser.newPage(); try { await page.goto('https://test.k6.io/'); diff --git a/examples/shadowdom.js b/examples/shadowdom.js index 0916a3706..a7d340ca5 100644 --- a/examples/shadowdom.js +++ b/examples/shadowdom.js @@ -18,7 +18,7 @@ export const options = { } export default async function() { - const page = browser.newPage(); + const page = await browser.newPage(); page.setContent("
hello!") await page.evaluate(() => { const shadowRoot = document.createElement('div'); diff --git a/examples/touchscreen.js b/examples/touchscreen.js index 3e2121760..d69be1be3 100644 --- a/examples/touchscreen.js +++ b/examples/touchscreen.js @@ -14,7 +14,7 @@ export const options = { } export default async function () { - const page = browser.newPage(); + const page = await browser.newPage(); await page.goto('https://test.k6.io/', { waitUntil: 'networkidle' });