Skip to content

Commit c8b1c79

Browse files
committed
[meta] prepare releases
1 parent 75f6e57 commit c8b1c79

File tree

6 files changed

+63
-7
lines changed

6 files changed

+63
-7
lines changed

nextest-runner/CHANGELOG.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
# Changelog
22

3-
## [0.72.0] - 2024-02-10
3+
## [0.73.0] - 2025-02-12
4+
5+
See the changelog for [cargo-nextest 0.9.90](https://nexte.st/changelog#0.9.90).
6+
7+
## [0.72.0] - 2025-02-10
48

59
See the changelog for [cargo-nextest 0.9.89](https://nexte.st/changelog#0.9.89).
610

7-
## [0.71.0] - 2024-01-15
11+
## [0.71.0] - 2025-01-15
812

913
See the changelog for [cargo-nextest 0.9.88](https://nexte.st/changelog#0.9.88).
1014

@@ -530,6 +534,7 @@ Thanks to [Guiguiprim](https://github.com/Guiguiprim) for their contributions to
530534

531535
- Initial version.
532536

537+
[0.73.0]: https://github.com/nextest-rs/nextest/releases/tag/nextest-runner-0.73.0
533538
[0.72.0]: https://github.com/nextest-rs/nextest/releases/tag/nextest-runner-0.72.0
534539
[0.71.0]: https://github.com/nextest-rs/nextest/releases/tag/nextest-runner-0.71.0
535540
[0.70.0]: https://github.com/nextest-rs/nextest/releases/tag/nextest-runner-0.70.0

site/src/changelog.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ toc_depth: 1
88
This page documents new features and bugfixes for cargo-nextest. Please see the [stability
99
policy](https://nexte.st/docs/stability/) for how versioning works with cargo-nextest.
1010

11+
## [0.9.90] - 2025-02-12
12+
13+
### Added
14+
15+
- Tests are now assigned global and group *slot numbers*. These numbers are non-negative integers starting from 0 that are unique for the lifetime of the test, but are reused after the test ends.
16+
17+
Global and group slot numbers can be accessed via the `NEXTEST_TEST_GLOBAL_SLOT` and `NEXTEST_TEST_GROUP_SLOT` environment variables, respectively. For more, see [*Slot numbers*](http://nexte.st/docs/configuration/test-groups#slot-numbers).
18+
19+
- [Test environments](http://nexte.st/docs/configuration/env-vars/#environment-variables-nextest-sets) now have the `NEXTEST_TEST_GROUP` variable set to the [test group](http://nexte.st/docs/configuration/test-groups) they're in, or `"@global"` if the test is not in any groups.
20+
1121
## [0.9.89] - 2025-02-10
1222

1323
### Added
@@ -1369,6 +1379,7 @@ Supported in this initial release:
13691379
- [Test retries](https://nexte.st/book/retries.md) and flaky test detection
13701380
- [JUnit support](https://nexte.st/book/junit.md) for integration with other test tooling
13711381

1382+
[0.9.90]: https://github.com/nextest-rs/nextest/releases/tag/cargo-nextest-0.9.90
13721383
[0.9.89]: https://github.com/nextest-rs/nextest/releases/tag/cargo-nextest-0.9.89
13731384
[0.9.88]: https://github.com/nextest-rs/nextest/releases/tag/cargo-nextest-0.9.88
13741385
[0.9.87]: https://github.com/nextest-rs/nextest/releases/tag/cargo-nextest-0.9.87

site/src/docs/configuration/env-vars.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,17 @@ Nextest exposes these environment variables to your tests _at runtime only_. The
8282
`NEXTEST_EXECUTION_MODE`
8383
: Currently, always set to `process-per-test`. More options may be added in the future if nextest gains the ability to run all tests within the same process ([#27]).
8484

85+
`NEXTEST_TEST_GROUP` <!-- md:version 0.9.90 -->
86+
: Set to the [test group](test-groups.md) the test is in, or `"@global"` if the test is not in any groups.
87+
88+
`NEXTEST_TEST_GLOBAL_SLOT` <!-- md:version 0.9.90 -->
89+
: Set to the [global slot number](test-groups.md#slot-numbers). Global slot numbers are non-negative integers starting from 0 that are unique within the run for the lifetime of the test, but are reused after the test finishes.
90+
91+
`NEXTEST_TEST_GROUP_SLOT` <!-- md:version 0.9.90 -->
92+
: If the test is in a group, set to the [group slot number](test-groups.md#slot-numbers). Group slot numbers are non-negative integers that are unique within the test group for the lifetime of the test, but are reused after the test finishes.
93+
94+
If the test is not in any groups, this is set to `"none"`.
95+
8596
`NEXTEST_BIN_EXE_<name>`
8697
: The absolute path to a binary target's executable. This is only set when running an [integration test] or benchmark. The `<name>` is the name of the binary target, exactly as-is. For example, `NEXTEST_BIN_EXE_my-program` for a binary named `my-program`.
8798

site/src/docs/configuration/test-groups.md

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ These test groups impact execution in the following ways:
7272

7373
Nextest will continue to schedule as many tests as possible, accounting for global and group concurrency limits.
7474

75+
<!-- md:version 0.9.90 --> The test group a test is running in is exposed via the `NEXTEST_TEST_GROUP` environment variable. If a test is not in any groups, this variable is set to `"@global"`.
76+
7577
## Showing test groups
7678

7779
You can show the test groups currently in effect with `cargo nextest show-config test-groups`.
@@ -94,6 +96,33 @@ group: <u style="text-decoration-style:single"><b>serial-integration</b></u> (ma
9496

9597
This command accepts [all the same options](../listing.md#options-and-arguments) that `cargo nextest list` does.
9698

99+
## Slot numbers
100+
101+
<!-- md:version 0.9.90 -->
102+
103+
Nextest assigns each test a *global slot number*. Additionally, if a test is in a group, the test is also assigned a *group slot number*.
104+
105+
Slot numbers are integers that start from 0 and go up from there. They are useful to assign resources such as blocks of port numbers to tests.
106+
107+
Slot numbers are:
108+
109+
* **Unique** for the lifetime of the test, either globally or within the group.
110+
111+
For example, if a test in the group `resource-limited` is assigned the global slot 10 and the group slot 5, then while this test is running:
112+
113+
- No other test within the same run will be assigned the global slot 10.
114+
- No other tests in the `resource-limited` group will be assigned the group slot 5.
115+
116+
After this test finishes, the global slot number 10 and the group slot number 5 are freed up, and can be reused for other tests.
117+
118+
* **Stable** across [retries](../features/retries.md) within the same run (though not across runs).
119+
120+
* **Compact**, in the sense that each test is always assigned the smallest possible slot number starting from 0, depending on which numbers are free at the time the test starts.
121+
122+
For example, if a test group is limited to serial execution, the group slot number is always 0 for those tests.
123+
124+
Global and group slot numbers can be accessed via the `NEXTEST_TEST_GLOBAL_SLOT` and `NEXTEST_TEST_GROUP_SLOT` [environment variables](env-vars.md#environment-variables-nextest-sets), respectively. (If a test is not within a group, `NEXTEST_TEST_GROUP_SLOT` is set to `none`.)
125+
97126
## Comparison with `threads-required`
98127

99128
Test groups are similar to [heavy tests and `threads-required`](threads-required.md). The key difference is that test groups are meant to limit concurrency for subsets of tests, while `threads-required` sets global limits across the entire test run.
@@ -118,7 +147,7 @@ threads-required = 1 # this is the default, shown for clarity
118147
With this configuration:
119148

120149
- Tests whose names start with `group::heavy::`, and tests that start with `group::light::`, are both part of `my-group`.
121-
- The `group::heavy::` tests will take up two slots within _both_ global and group concurrency limits.
122-
- The `group::light::` tests will take up one slot within both limits.
150+
- The `group::heavy::` tests will take up two threads within _both_ global and group concurrency limits.
151+
- The `group::light::` tests will take up one thread within both limits.
123152

124-
> **Note:** Setting `threads-required` to be greater than a test group's `max-threads` will not cause issues; a test that does so will take up all slots available.
153+
> **Note:** Setting `threads-required` to be greater than a test group's `max-threads` will not cause issues; a test that does so will take up all threads available.

site/src/docs/configuration/threads-required.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ icon: material/weight-lifter
66

77
Nextest achieves [its performance](../benchmarks/index.md) through running [many tests in parallel](../design/how-it-works.md). However, some projects have tests that consume a disproportionate amount of resources like CPU or memory. If too many of these _heavy tests_ are run concurrently, your machine's CPU might be overwhelmed, or it might run out of memory.
88

9-
With nextest, you can mark heavy tests as taking up multiple threads or "slots" out of the total amount of available parallelism. In other words, you can assign those tests a higher "weight". This is done by using the `threads-required` [per-test override](per-test-overrides.md).
9+
With nextest, you can mark heavy tests as taking up multiple threads out of the total amount of available parallelism. In other words, you can assign those tests a higher "weight". This is done by using the `threads-required` [per-test override](per-test-overrides.md).
1010

1111
For example, on a machine with 16 logical CPUs, nextest will run 16 tests concurrently by default. However, if you mark tests that begin with `tests::heavy::` as requiring 2 threads each:
1212

site/src/docs/running.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ fail-fast = { max-fail = "all" }
229229
* a positive integer (e.g. `8`) to run that many tests simultaneously.
230230
* a negative integer (e.g. `-2`) to run available parallelism minus that many tests simultaneously. For example, on a machine with 8 CPU hyperthreads, `-2` would run 6 tests simultaneously.
231231

232-
Tests can be marked as taking up more than one available slot. For more, see [*Heavy tests and `threads-required`*](configuration/threads-required.md).
232+
Tests can be marked as taking up more than one available thread. For more, see [*Heavy tests and `threads-required`*](configuration/threads-required.md).
233233

234234
`--run-ignored=only` <!-- md:version 0.9.76 -->
235235
: Run only ignored tests. (With prior nextest versions, use `--run-ignored=ignored-only`.)

0 commit comments

Comments
 (0)