Skip to content

Commit 8e7dc38

Browse files
inancgumusmdcruz
andcommitted
Improve migration guide explanations
Co-authored-by: Marie Cruz <[email protected]>
1 parent 2af327b commit 8e7dc38

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/data/markdown/translated-guides/en/03 Using k6 browser/04 Migrating to k6 v0-46.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Users no longer need to use the `K6_BROWSER_ENABLED` flag when running browser t
1515
</Blockquote>
1616

1717

18-
## Key Changes in the New API
18+
## Key changes in the new API
1919

2020
The updated k6 browser API introduces notable structural changes in its operation and API.
2121

@@ -94,9 +94,9 @@ export default async function () {
9494

9595

9696

97-
## Import Path
97+
## Import path
9898

99-
Changes have been made to the way the [browser module](/javascript-api/k6-experimental/browser/) is imported. With the browser type (i.e., `chromium`) now set in [scenario options](#scenario-options), users should directly import the [browser](/javascript-api/k6-experimental/browser/#browser-module-api) object from the [browser module](/javascript-api/k6-experimental/browser/). In the past, users would rely on `chromium.launch()` for accessing the running browser. Now, a simple import of the [browser](/javascript-api/k6-experimental/browser/#browser-module-api) sufficient.
99+
Changes have been made to how the [browser module](/javascript-api/k6-experimental/browser/) is imported. With the browser type (i.e., `chromium`) now set in [scenario options](#scenario-options), users should directly import the [browser](/javascript-api/k6-experimental/browser/#browser-module-api) object from the [browser module](/javascript-api/k6-experimental/browser/). In the past, users relied on `chromium.launch()` for accessing the running browser. Now, a simple import of the [browser](/javascript-api/k6-experimental/browser/#browser-module-api) is sufficient.
100100

101101
<CodeGroup labels={["Before: Import Path"]} lineNumbers={[true]}>
102102

@@ -151,9 +151,9 @@ The following browser options are no longer supported: `slowMo`, `devtools`, `en
151151

152152
## Scenario options
153153

154-
In the new update, users must set the browser type as an option in a [k6 scenario](/using-k6/scenarios/) definition. Specifically, the `browser.type` option should be set to `chromium`, as Chromium is the only browser supported.
154+
In the new update, users must set the [executor](/using-k6/scenarios/executors/) and browser type as options in a [k6 scenario](/using-k6/scenarios/) definition. Specifically, the `browser.type` option should be set to `chromium`, as Chromium is the only browser supported.
155155

156-
This change helps identify the test as a browser test and allows automatic control of the browser's lifecycle. Users no longer need to start or stop the browser manually through the browser API. If the `browser.type` option is set in the scenario options, a browser instance will be automatically started at the beginning and closed at the end of each test iteration.
156+
This change helps identify the test as a browser test and allows automatic control of the browser's lifecycle. Users no longer need to start or stop the browser manually through the browser API. If the `browser.type` option is set in the scenario options, a browser instance will automatically start at the beginning and close at the end of each test iteration.
157157

158158
<CodeGroup labels={["After"]} lineNumbers={[true]}>
159159

0 commit comments

Comments
 (0)