|
| 1 | +# Internal links show a copyable slug; external links retain their URL. |
| 2 | +exec ./k6 x docs --cache-dir $WORK/links --version v1.6.x get-started write-your-first-test |
| 3 | +cmp stdout expected.md |
| 4 | + |
| 5 | +# TTY output, search navigation, and the best-practices page share the transform. |
| 6 | +env NO_COLOR=1 |
| 7 | +ptyexec ./k6 x docs --cache-dir $WORK/links --version v1.6.x get-started write-your-first-test |
| 8 | +cp stdout tty.md |
| 9 | +containslines expected.md tty.md |
| 10 | +exec ./k6 x docs --cache-dir $WORK/links --version v1.6.x search get-started/write-your-first-test |
| 11 | +cmp stdout expected.md |
| 12 | +cp links/v1.6.x/markdown/first.md links/v1.6.x/best_practices.md |
| 13 | +exec ./k6 x docs --cache-dir $WORK/links --version v1.6.x best-practices |
| 14 | +cmp stdout expected.md |
| 15 | + |
| 16 | +# Local source previews keep links through bundle preparation too. |
| 17 | +mkdir src/docs/sources/k6/v1.6.x/get-started |
| 18 | +cp links/v1.6.x/markdown/first.md src/docs/sources/k6/v1.6.x/get-started/write-your-first-test.md |
| 19 | +cp links/v1.6.x/markdown/running.md src/docs/sources/k6/v1.6.x/get-started/running-k6.md |
| 20 | +cp index.md src/docs/sources/k6/v1.6.x/get-started/_index.md |
| 21 | +exec ./k6 x docs --cache-dir $WORK/source-cache --source $WORK/src --version v1.6.x get-started write-your-first-test |
| 22 | +cmp stdout expected.md |
| 23 | + |
| 24 | +-- links/v1.6.x/sections.json -- |
| 25 | +{"version":"v1.6.x","sections":[{"slug":"get-started/write-your-first-test","rel_path":"first.md"},{"slug":"get-started/running-k6","rel_path":"running.md"}]} |
| 26 | +-- links/v1.6.x/markdown/first.md -- |
| 27 | +Refer to [Running k6](https://grafana.com/docs/k6/<K6_VERSION>/get-started/running-k6/) to learn how to execute your script. |
| 28 | +Use [Visual Studio Code](https://code.visualstudio.com/) to edit it. |
| 29 | +See [details](https://grafana.com/docs/k6/v1.6.1/get-started/running-k6/#results) and [root-relative](/docs/k6/<K6_VERSION>/get-started/running-k6). |
| 30 | +Keep [older docs](https://grafana.com/docs/k6/v1.5.x/get-started/running-k6/), [other docs](https://grafana.com/docs/grafana-cloud/testing/k6/), and [another host](https://example.com/docs/k6/v1.6.x/get-started/running-k6/). |
| 31 | +Keep [section](#results), [docs home](https://grafana.com/docs/k6/<K6_VERSION>/), and [web parentheses](https://en.wikipedia.org/wiki/HAR_(file_format)). |
| 32 | +Image: . |
| 33 | +-- links/v1.6.x/markdown/running.md -- |
| 34 | +# Running k6 |
| 35 | +-- expected.md -- |
| 36 | +Refer to Running k6 (`get-started/running-k6`) to learn how to execute your script. |
| 37 | +Use [Visual Studio Code](https://code.visualstudio.com/) to edit it. |
| 38 | +See details (`get-started/running-k6`) and root-relative (`get-started/running-k6`). |
| 39 | +Keep [older docs](https://grafana.com/docs/k6/v1.5.x/get-started/running-k6/), [other docs](https://grafana.com/docs/grafana-cloud/testing/k6/), and [another host](https://example.com/docs/k6/v1.6.x/get-started/running-k6/). |
| 40 | +Keep [section](#results), [docs home](https://grafana.com/docs/k6/v1.6.x/), and [web parentheses](https://en.wikipedia.org/wiki/HAR_(file_format)). |
| 41 | +Image: diagram. |
| 42 | +-- index.md -- |
| 43 | +--- |
| 44 | +title: Get started |
| 45 | +--- |
0 commit comments