Project

PSPublishModule

Build, test, version, sign, and publish PowerShell modules with reusable PowerForge pipelines.

Stars 48
Forks 16
PowerShell Gallery downloads 17,213
Release v3.0.186
Language: C# Updated: 2026-11-04
Command

Invoke-BenchmarkSuite

Module
PSPublishModule
Inputs
None
Outputs
PowerForge.BenchmarkRunResult PowerForge.PowerShellBenchmarkWorkItem

Runs a reusable PowerShell benchmark suite.

Syntax

Invoke-BenchmarkSuite
[-Case <String[]>]
[-Cleanup <Always|KeepOnFailure|KeepAlways>]
[-CooldownMilliseconds <Int32>]
[-Engine <String[]>]
[-ExternalHostTimeoutSeconds <Int32>]
[-HostName <String[]>]
[-IterationCount <Int32>]
[-MemoryCleanup <BeforeIteration>]
[-Operation <String[]>]
[-OutlierMode <ExcludeMinMax>]
[-OutputRoot <String>]
[-Path] <String>
[-Plan]
[-Profile <Current|TemporaryLocalUser>]
[-RunMode <String>]
[-RunOrder <Sequential|Rotated|Randomized|GroupedRotated>]
[-Suite <String>]
[-Variable <Hashtable>]
[-WarmupCount <Int32>]
[<CommonParameters>]
#
Parameter set: Path
Invoke-BenchmarkSuite
[-Case <String[]>]
[-Cleanup <Always|KeepOnFailure|KeepAlways>]
[-CooldownMilliseconds <Int32>]
[-Engine <String[]>]
[-ExternalHostTimeoutSeconds <Int32>]
[-HostName <String[]>]
[-IterationCount <Int32>]
[-MemoryCleanup <BeforeIteration>]
[-Operation <String[]>]
[-OutlierMode <ExcludeMinMax>]
[-OutputRoot <String>]
[-Plan]
[-Profile <Current|TemporaryLocalUser>]
[-RunMode <String>]
[-RunOrder <Sequential|Rotated|Randomized|GroupedRotated>]
[-Settings] <ScriptBlock>
[-Suite <String>]
[-Variable <Hashtable>]
[-WarmupCount <Int32>]
[<CommonParameters>]
#
Parameter set: Settings

Examples

Run a benchmark spec

Invoke-BenchmarkSuite -Path .\Benchmarks\module.benchmark.ps1

Parameters

-Case String[] optionalaliases: Cases, Scenario, Scenarios
Case or scenario names to include.
-Cleanup PowerShellBenchmarkCleanupMode optional
Optional cleanup override.
Possible values: Always, KeepOnFailure, KeepAlways
-CooldownMilliseconds Int32 optional
Optional delay between measured samples, in milliseconds.
-Engine String[] optionalaliases: Engines
Engine names to include.
-ExternalHostTimeoutSeconds Int32 optional
Maximum time allowed for each external PowerShell host process.
-HostName String[] optionalaliases: Host, Hosts
Host labels to include.
-IterationCount Int32 optional
Optional measured iteration count override.
-MemoryCleanup PowerShellBenchmarkMemoryCleanupMode optional
Optional managed-memory cleanup override.
Possible values: BeforeIteration
-Operation String[] optionalaliases: Operations
Operation names to include.
-OutlierMode PowerShellBenchmarkOutlierMode optional
Optional summary outlier policy override.
Possible values: ExcludeMinMax
-OutputRoot String optional
Optional output root override.
-Path String requiredposition: 0sets: Path
Path to a .benchmark.ps1 spec.
-Plan SwitchParameter optional
Prints the resolved plan instead of executing measurements.
-Profile PowerShellBenchmarkProfileKind optional
Optional profile override.
Possible values: Current, TemporaryLocalUser
-RunMode String optional
Run mode label.
-RunOrder PowerShellBenchmarkRunOrder optional
Optional work-item ordering override.
Possible values: Sequential, Rotated, Randomized, GroupedRotated
-Suite String optional
Optional suite name override.
-Variable Hashtable optionalaliases: Variables
Optional variables exposed to benchmark specs as $BenchmarkVariables.
-WarmupCount Int32 optional
Optional warmup count override.
-Settings ScriptBlock requiredposition: 0sets: Settings
Inline benchmark DSL settings.

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.