From 2b51935a1aee6e94eae9ef3a54b85083439577de Mon Sep 17 00:00:00 2001 From: nohwnd Date: Tue, 30 Jun 2026 10:44:51 +0200 Subject: [PATCH 1/3] docs: fix dead Microsoft Virtual Academy course link Microsoft Virtual Academy was retired; the "Testing PowerShell with Pester" course now lives on Microsoft Learn. Point the resources table at the canonical Learn URL instead of relying on the old MVA redirect. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/additional-resources/courses.table.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/additional-resources/courses.table.js b/docs/additional-resources/courses.table.js index b5069ccb..5571d20f 100644 --- a/docs/additional-resources/courses.table.js +++ b/docs/additional-resources/courses.table.js @@ -7,7 +7,7 @@ export const courses = [ { title: "Testing PowerShell with Pester", author: "Ashley McGlone, Adam Bertram", - url: "https://mva.microsoft.com/en-US/training-courses/17650?l=mg8oBM9vD_8811787177", + url: "https://learn.microsoft.com/en-us/shows/testing-powershell-with-pester/", }, { title: "PSKoans - A simple, fun, and interactive way to learn the PowerShell language through Pester unit testing", From 4d73e45661fb7d527e0eb7b4520cb044f6f1ef86 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Tue, 30 Jun 2026 15:23:08 +0200 Subject: [PATCH 2/3] =?UTF-8?q?docs:=20add=20'New=20in=20v6=20(optional)'?= =?UTF-8?q?=20section=20to=20v5=E2=86=92v6=20guide?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Consolidate the optional features worth adopting after upgrading (parallel runs, Debug.ShowStartMarkers, Should-* assertions) under one heading, and drop the dangling 'a dedicated guide will come later' promise in favor of practical incremental-adoption guidance. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/migrations/v5-to-v6.mdx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/docs/migrations/v5-to-v6.mdx b/docs/migrations/v5-to-v6.mdx index 1fe5b872..3c70527a 100644 --- a/docs/migrations/v5-to-v6.mdx +++ b/docs/migrations/v5-to-v6.mdx @@ -229,13 +229,23 @@ $config.CodeCoverage.Path = './src' Invoke-Pester -Configuration $config ``` -## New `Should-*` assertions (optional) +## New in v6 (optional) -Pester 6 adds a new family of `Should-*` assertions — `Should-Be`, `Should-Throw`, `Should-Invoke` and around 40 more — with clearer failure messages. They are **not** part of upgrading: your existing `Should -Be` assertions keep working, and there is no need to rewrite them. +None of these are required to upgrade — your v5 suite keeps working without them. They are the main things v6 adds that you may want to adopt once your suite is green. -If you want to try them, see the [command reference](../commands/Should-Be). A dedicated guide for moving from `Should -Be` to `Should-Be` will come later. +### Run test files in parallel -### Piping vs. `-Actual` +The per-file model lets v6 run whole test files concurrently, each in its own runspace, which can cut the wall-clock time of a large suite. It is opt-in and still experimental — enable it with `Run.Parallel = $true`. Files that need shared bootstrap can use `Run.BeforeContainer` (or a `Pester.BeforeContainer.ps1` in the repository root) so each worker starts from a known state. See [Parallel execution](../usage/parallel) for the requirements, sequential fallbacks, and the `#pester:no-parallel` opt-out. + +### Show which test is currently running + +In a long or stuck suite it can be hard to tell which test is executing. Set `Debug.ShowStartMarkers = $true` to print a marker as each test starts, before its result line is written. See [Showing when each test starts](../usage/output#showing-when-each-test-starts). + +### New `Should-*` assertions + +Pester 6 adds a new family of `Should-*` assertions — `Should-Be`, `Should-Throw`, `Should-Invoke` and around 40 more — with clearer failure messages. They are **not** part of upgrading: your existing `Should -Be` assertions keep working, and there is no need to rewrite them. If you want to try them, see the [Should assertions overview](../assertions/should-command) and the per-command reference. You can adopt them incrementally, one file at a time. + +#### Piping vs. `-Actual` The new assertions take the actual value from the pipeline or from `-Actual`. The pipeline unwraps its input, so a **value** assertion sees `@(1)` as `1` and `@()` as `$null`, and a collection sent through the pipeline is re-collected as `[object[]]` — its original type (for example `[int[]]`) is lost. Use `-Actual` when you need the exact value or the concrete collection type: From ab301fdc801f30a649d865cfc465a6815ca16002 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Tue, 30 Jun 2026 15:23:08 +0200 Subject: [PATCH 3/3] =?UTF-8?q?docs:=20add=20'New=20in=20v6=20(optional)'?= =?UTF-8?q?=20section=20to=20v5=E2=86=92v6=20guide?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Consolidate the optional features worth adopting after upgrading (parallel runs, Debug.ShowStartMarkers, Should-* assertions) under one heading, and drop the dangling 'a dedicated guide will come later' promise in favor of practical incremental-adoption guidance. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/migrations/v5-to-v6.mdx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/docs/migrations/v5-to-v6.mdx b/docs/migrations/v5-to-v6.mdx index 1fe5b872..3c70527a 100644 --- a/docs/migrations/v5-to-v6.mdx +++ b/docs/migrations/v5-to-v6.mdx @@ -229,13 +229,23 @@ $config.CodeCoverage.Path = './src' Invoke-Pester -Configuration $config ``` -## New `Should-*` assertions (optional) +## New in v6 (optional) -Pester 6 adds a new family of `Should-*` assertions — `Should-Be`, `Should-Throw`, `Should-Invoke` and around 40 more — with clearer failure messages. They are **not** part of upgrading: your existing `Should -Be` assertions keep working, and there is no need to rewrite them. +None of these are required to upgrade — your v5 suite keeps working without them. They are the main things v6 adds that you may want to adopt once your suite is green. -If you want to try them, see the [command reference](../commands/Should-Be). A dedicated guide for moving from `Should -Be` to `Should-Be` will come later. +### Run test files in parallel -### Piping vs. `-Actual` +The per-file model lets v6 run whole test files concurrently, each in its own runspace, which can cut the wall-clock time of a large suite. It is opt-in and still experimental — enable it with `Run.Parallel = $true`. Files that need shared bootstrap can use `Run.BeforeContainer` (or a `Pester.BeforeContainer.ps1` in the repository root) so each worker starts from a known state. See [Parallel execution](../usage/parallel) for the requirements, sequential fallbacks, and the `#pester:no-parallel` opt-out. + +### Show which test is currently running + +In a long or stuck suite it can be hard to tell which test is executing. Set `Debug.ShowStartMarkers = $true` to print a marker as each test starts, before its result line is written. See [Showing when each test starts](../usage/output#showing-when-each-test-starts). + +### New `Should-*` assertions + +Pester 6 adds a new family of `Should-*` assertions — `Should-Be`, `Should-Throw`, `Should-Invoke` and around 40 more — with clearer failure messages. They are **not** part of upgrading: your existing `Should -Be` assertions keep working, and there is no need to rewrite them. If you want to try them, see the [Should assertions overview](../assertions/should-command) and the per-command reference. You can adopt them incrementally, one file at a time. + +#### Piping vs. `-Actual` The new assertions take the actual value from the pipeline or from `-Actual`. The pipeline unwraps its input, so a **value** assertion sees `@(1)` as `1` and `@()` as `$null`, and a collection sent through the pipeline is re-collected as `[object[]]` — its original type (for example `[int[]]`) is lost. Use `-Actual` when you need the exact value or the concrete collection type: