Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion docs/developer-guide/160-frontend-testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,16 @@ test("My app test", async ({ assetsPage }) => {

### Running the test

To run all frontend tests, use:

```sh
./gradlew npmTest
```

::::note
Avoid using the `npmTestUI` task without specifying a path, or you'll open a Playwright window for each project.
::::
Comment on lines +219 to +221

@wborn wborn Aug 27, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://docusaurus.io/docs/markdown-features/admonitions

Suggested change
::::note
Avoid using the `npmTestUI` task without specifying a path, or you'll open a Playwright window for each project.
::::
:::note
Avoid using the `npmTestUI` task without specifying a path, or you'll open a Playwright window for each project.
:::

@wborn wborn Aug 27, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The extra new lines prevent issues if we start using prettier as Markdown formatter:

https://docusaurus.io/docs/markdown-features/admonitions#usage-with-prettier


The best way to run and debug your tests in Playwright is by using the [Playwright UI mode](https://playwright.dev/docs/test-ui-mode) feature.

You may consider adding a Gradle task to the `build.gradle` file in the component / app directory to open it:
Expand All @@ -224,7 +234,7 @@ tasks.register('npmTestUI', Exec) {
Then run it with:

```sh
gradle ui:component:or-<my-component>:npmTestUI
./gradlew ui:component:or-<my-component>:npmTestUI
```

Or simply run `npm test -- --ui` in the component / app directory.
Expand Down