Skip to content
Merged
Show file tree
Hide file tree
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
5 changes: 2 additions & 3 deletions docs-site/docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ execution:
baseUrl: https://your-app.com
gridUrl: http://localhost:4444 # only for remote mode

parallel: none # none | methods | classes | tests
parallel: none # none | methods | classes
threadCount: 1 # ignored when parallel: none
maxActiveSessions: 5 # max concurrent browser instances (semaphore)

Expand Down Expand Up @@ -181,14 +181,13 @@ Use `per-suite` when your suite has many sequential tests and browser startup ti
## Execution

### `parallel`
Maps directly to TestNG parallel execution mode. Thread count is set via `threadCount`.
Maps directly to TestNG parallel execution mode. Thread count is set via `threadCount`. Selenium Boot validates this value at suite bootstrap and rejects anything outside the three below — TestNG's `tests` mode is not currently accepted.

| Value | Behaviour |
|---|---|
| `none` | Sequential execution (default) |
| `methods` | Each `@Test` method runs in its own thread |
| `classes` | Each test class runs in its own thread |
| `tests` | Each `<test>` block in testng.xml runs in its own thread |

### `maxActiveSessions`
Maximum concurrent browser instances. Tests wait (up to 30s) for a slot rather than failing immediately. Prevents resource exhaustion in parallel runs.
Expand Down
5 changes: 2 additions & 3 deletions docs-site/docs/guides/parallel.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Selenium Boot supports parallel test execution out of the box. Configure the thr
```yaml title="selenium-boot.yml"
execution:
mode: local
parallel: methods # none (default) | methods | classes | tests
parallel: methods # none (default) | methods | classes
threadCount: 4 # number of concurrent browser sessions
maxActiveSessions: 4 # semaphore cap — cannot exceed threadCount

Expand Down Expand Up @@ -85,13 +85,12 @@ You do not need to do anything special in your tests. `getDriver()` always retur

## Parallel modes

TestNG supports several parallel modes. Selenium Boot works with all of them:
TestNG supports several parallel modes. Selenium Boot currently validates `execution.parallel` against `none`, `methods`, and `classes` — any other value (including TestNG's `tests` mode) is rejected at suite bootstrap, before any test runs.

| Mode | Description | Recommended |
|---|---|---|
| `methods` | Each test method runs in its own thread | Best general choice |
| `classes` | Each test class runs in a thread | Use when tests within a class must be sequential |
| `tests` | Each `<test>` tag in suite XML runs in a thread | For suite-level isolation |

---

Expand Down
Loading