Skip to content

Fix #2515, #2538, #2678: Hidden folder discovery, error reporting, CimInstance#2687

Closed
nohwnd wants to merge 1 commit intopester:mainfrom
nohwnd:fix-runtime
Closed

Fix #2515, #2538, #2678: Hidden folder discovery, error reporting, CimInstance#2687
nohwnd wants to merge 1 commit intopester:mainfrom
nohwnd:fix-runtime

Conversation

@nohwnd
Copy link
Copy Markdown
Member

@nohwnd nohwnd commented Apr 3, 2026

Pester 6 Fixes (Copilot-generated)

Fix #2515: Hidden folders included in test discovery

Added -Force to Get-ChildItem calls in Find-File so hidden (dot-prefixed) folders like .github are included on Linux.

Fix #2538: Discovery errors reported as Failed

Container/block with discovery errors now correctly reported as Failed instead of Passed. Reordered result-computation logic so non-empty ErrorRecord always yields Failed.

Fix #2678: Suppress Get-CimInstance access denied

Added -ErrorAction Ignore to Get-CimInstance and Get-WmiObject calls in Get-RunTimeEnvironment with null fallback for OS info when not running as Administrator.

All 2154 tests pass locally.

Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com

…rror reporting, CimInstance

pester#2515: Include hidden (dot-prefixed) folders in test discovery on Linux
by adding -Force to Get-ChildItem calls in Find-File.

pester#2538: Container/block with discovery errors now reported as Failed
instead of incorrectly showing as Passed.

pester#2678: Suppress Get-CimInstance access denied error when Pester runs
without Administrator rights by adding -ErrorAction Ignore.

Copilot-generated fix.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@nohwnd
Copy link
Copy Markdown
Member Author

nohwnd commented Apr 3, 2026

split this per issue fix into multiple PRs, not sure what you are doing.

@nohwnd
Copy link
Copy Markdown
Member Author

nohwnd commented Apr 3, 2026

Superseded by individual PRs per review feedback. Each fix now has its own PR (#2689-#2697).

@nohwnd nohwnd closed this Apr 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant