From dd43ae2525e3782b2a1832083026394ce0a39d10 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Fri, 17 May 2024 22:20:42 +0200 Subject: [PATCH] Hide legacy-only parameters in Invoke-Pester (#2446) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Use new certificate thumbprint * Hide legacy-only parameters in Invoke-Pester --------- Co-authored-by: Jakub Jareš --- src/Main.ps1 | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/Main.ps1 b/src/Main.ps1 index 4c87029f6..14b9a82a1 100644 --- a/src/Main.ps1 +++ b/src/Main.ps1 @@ -630,39 +630,39 @@ function Invoke-Pester { [PesterConfiguration] $Configuration, # rest of the Legacy set - [Parameter(Position = 2, Mandatory = 0, ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(Position = 2, Mandatory = 0, ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [switch]$EnableExit, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [object[]] $CodeCoverage = @(), - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [string] $CodeCoverageOutputFile, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [string] $CodeCoverageOutputFileEncoding = 'utf8', - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [ValidateSet('JaCoCo')] [String]$CodeCoverageOutputFileFormat = "JaCoCo", - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [Switch]$Strict, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [string] $OutputFile, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [ValidateSet('NUnitXml', 'NUnit2.5', 'JUnitXml')] [string] $OutputFormat = 'NUnitXml', - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [Switch]$Quiet, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [object]$PesterOption, - [Parameter(ParameterSetName = "Legacy")] # Legacy set for v4 compatibility during migration - deprecated + [Parameter(ParameterSetName = "Legacy", DontShow)] # Legacy set for v4 compatibility during migration - deprecated [Pester.OutputTypes]$Show = 'All' ) begin {