From 5e966a3db652f2e6c5fbcacbcc63c5b2ad726b5e Mon Sep 17 00:00:00 2001 From: emilioalvap Date: Mon, 7 Apr 2025 18:02:21 +0200 Subject: [PATCH] Fix async step callback --- solutions/observability/apps/write-synthetic-test.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/solutions/observability/apps/write-synthetic-test.md b/solutions/observability/apps/write-synthetic-test.md index 1fb4d2996a..a2e2cf16c6 100644 --- a/solutions/observability/apps/write-synthetic-test.md +++ b/solutions/observability/apps/write-synthetic-test.md @@ -98,10 +98,10 @@ A basic two-step journey would look like this: ```js journey('Journey name', ({ page, browser, client, params, request }) => { - step('Step 1 name', () => { + step('Step 1 name', async () => { // Do something here }); - step('Step 2 name', () => { + step('Step 2 name', async () => { // Do something else here }); }); @@ -110,7 +110,7 @@ journey('Journey name', ({ page, browser, client, params, request }) => { Steps can be as simple or complex as you need them to be. For example, a basic first step might load a web page: ```js -step('Load the demo page', () => { +step('Load the demo page', async () => { await page.goto('https://elastic.github.io/synthetics-demo/'); <1> }); ```