From 17449a070af65d451e5f3f5d1cec6b332dd86f45 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Thu, 16 Jul 2026 20:54:41 +0000 Subject: [PATCH 1/6] Baseline Alt3.Docusaurus.PowerShell v2 command reference --- docs/commands/Add-ShouldOperator.mdx | 154 +- docs/commands/AfterAll.mdx | 37 +- docs/commands/AfterEach.mdx | 37 +- docs/commands/BeforeAll.mdx | 37 +- docs/commands/BeforeDiscovery.mdx | 37 +- docs/commands/BeforeEach.mdx | 37 +- docs/commands/Context.mdx | 209 +- docs/commands/ConvertTo-JUnitReport.mdx | 75 +- docs/commands/ConvertTo-NUnitReport.mdx | 102 +- docs/commands/ConvertTo-Pester4Result.mdx | 39 +- docs/commands/Describe.mdx | 215 +- docs/commands/Export-JUnitReport.mdx | 74 +- docs/commands/Export-NUnitReport.mdx | 97 +- docs/commands/Get-ShouldOperator.mdx | 37 +- docs/commands/InModuleScope.mdx | 123 +- docs/commands/Invoke-Pester.mdx | 320 +-- docs/commands/It.mdx | 205 +- docs/commands/Mock.mdx | 207 +- docs/commands/New-Fixture.mdx | 69 +- docs/commands/New-MockObject.mdx | 179 +- docs/commands/New-PesterConfiguration.mdx | 40 +- docs/commands/New-PesterContainer.mdx | 104 +- docs/commands/Set-ItResult.mdx | 102 +- docs/commands/Should-All.mdx | 98 +- docs/commands/Should-Any.mdx | 98 +- docs/commands/Should-Be.mdx | 93 +- docs/commands/Should-BeAfter.mdx | 213 +- docs/commands/Should-BeBefore.mdx | 213 +- docs/commands/Should-BeCollection.mdx | 125 +- docs/commands/Should-BeEmptyString.mdx | 62 +- docs/commands/Should-BeEquivalent.mdx | 174 +- docs/commands/Should-BeFalse.mdx | 65 +- docs/commands/Should-BeFalsy.mdx | 65 +- docs/commands/Should-BeFasterThan.mdx | 93 +- docs/commands/Should-BeGreaterThan.mdx | 93 +- docs/commands/Should-BeGreaterThanOrEqual.mdx | 93 +- docs/commands/Should-BeHashtable.mdx | 155 +- docs/commands/Should-BeLessThan.mdx | 93 +- docs/commands/Should-BeLessThanOrEqual.mdx | 93 +- docs/commands/Should-BeLikeString.mdx | 117 +- docs/commands/Should-BeNull.mdx | 62 +- docs/commands/Should-BeSame.mdx | 93 +- docs/commands/Should-BeSlowerThan.mdx | 93 +- docs/commands/Should-BeString.mdx | 168 +- docs/commands/Should-BeTrue.mdx | 65 +- docs/commands/Should-BeTruthy.mdx | 65 +- docs/commands/Should-ContainCollection.mdx | 98 +- docs/commands/Should-HaveParameter.mdx | 273 ++- docs/commands/Should-HaveType.mdx | 93 +- docs/commands/Should-Invoke.mdx | 317 +-- docs/commands/Should-MatchString.mdx | 117 +- docs/commands/Should-NotBe.mdx | 93 +- docs/commands/Should-NotBeEmptyString.mdx | 62 +- docs/commands/Should-NotBeLikeString.mdx | 118 +- docs/commands/Should-NotBeNull.mdx | 62 +- docs/commands/Should-NotBeSame.mdx | 93 +- docs/commands/Should-NotBeString.mdx | 145 +- .../commands/Should-NotBeWhiteSpaceString.mdx | 62 +- docs/commands/Should-NotContainCollection.mdx | 98 +- docs/commands/Should-NotHaveParameter.mdx | 104 +- docs/commands/Should-NotHaveType.mdx | 93 +- docs/commands/Should-NotInvoke.mdx | 319 +-- docs/commands/Should-NotMatchString.mdx | 117 +- docs/commands/Should-Throw.mdx | 179 +- docs/commands/Should.mdx | 1961 ++++++++++------- generate-command-reference.ps1 | 42 +- 66 files changed, 5652 insertions(+), 3819 deletions(-) diff --git a/docs/commands/Add-ShouldOperator.mdx b/docs/commands/Add-ShouldOperator.mdx index 8548e00..9a21df2 100644 --- a/docs/commands/Add-ShouldOperator.mdx +++ b/docs/commands/Add-ShouldOperator.mdx @@ -23,8 +23,8 @@ Register a Should Operator with Pester ## SYNTAX ```powershell -Add-ShouldOperator [-Name] [-Test] [[-Alias] ] [[-InternalName] ] - [-SupportsArrayInput] [] +Add-ShouldOperator [-Name] [-Test] [[-Alias] ] + [[-InternalName] ] [-SupportsArrayInput] ``` ## DESCRIPTION @@ -67,92 +67,120 @@ Example of how to create a simple custom assertion that checks if the input stri ## PARAMETERS -### -Name +### -Alias -The name of the assertion. -This will become a Named Parameter of Should. +A list of aliases for the Named Parameter. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '@()' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Test +### -InternalName -The test function. -The function must return a PSObject with a [Bool]succeeded and a [string]failureMessage property. +If -Name is different from the actual function name, record the actual function name here. +Used by Get-ShouldOperator to pull function help. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Alias +### -Name -A list of aliases for the Named Parameter. +The name of the assertion. +This will become a Named Parameter of Should. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -InternalName +### -SupportsArrayInput -If -Name is different from the actual function name, record the actual function name here. -Used by Get-ShouldOperator to pull function help. +Does the test function support the passing an array of values to test. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 4 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -SupportsArrayInput +### -Test -Does the test function support the passing an array of values to test. +The test function. +The function must return a PSObject with a [Bool]succeeded and a [string]failureMessage property. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -162,8 +190,8 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Add-ShouldOperator](https://pester.dev/docs/commands/Add-ShouldOperator) +- [https://pester.dev/docs/commands/Add-ShouldOperator](https://pester.dev/docs/commands/Add-ShouldOperator) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/AfterAll.mdx b/docs/commands/AfterAll.mdx index 9b4dff2..71bceb7 100644 --- a/docs/commands/AfterAll.mdx +++ b/docs/commands/AfterAll.mdx @@ -24,7 +24,7 @@ Context or Describe block. ## SYNTAX ```powershell -AfterAll [-Scriptblock] [] +AfterAll [-Scriptblock] ``` ## DESCRIPTION @@ -78,20 +78,28 @@ the tests in the Describe-block. A scriptblock with steps to be executed during teardown. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -101,10 +109,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/AfterAll](https://pester.dev/docs/commands/AfterAll) - -[https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) +- [https://pester.dev/docs/commands/AfterAll](https://pester.dev/docs/commands/AfterAll) +- [https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/AfterEach.mdx b/docs/commands/AfterEach.mdx index b1e8985..019a910 100644 --- a/docs/commands/AfterEach.mdx +++ b/docs/commands/AfterEach.mdx @@ -24,7 +24,7 @@ the current Context or Describe block. ## SYNTAX ```powershell -AfterEach [-Scriptblock] [] +AfterEach [-Scriptblock] ``` ## DESCRIPTION @@ -75,20 +75,28 @@ The example uses AfterEach to remove a temporary file after each test. A scriptblock with steps to be executed during teardown. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -98,10 +106,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/AfterEach](https://pester.dev/docs/commands/AfterEach) - -[https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) +- [https://pester.dev/docs/commands/AfterEach](https://pester.dev/docs/commands/AfterEach) +- [https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/BeforeAll.mdx b/docs/commands/BeforeAll.mdx index b92b32c..e2e5483 100644 --- a/docs/commands/BeforeAll.mdx +++ b/docs/commands/BeforeAll.mdx @@ -24,7 +24,7 @@ Context or Describe block. ## SYNTAX ```powershell -BeforeAll [-Scriptblock] [] +BeforeAll [-Scriptblock] ``` ## DESCRIPTION @@ -87,20 +87,28 @@ the results in separate tests. A scriptblock with steps to be executed during setup. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -110,10 +118,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/BeforeAll](https://pester.dev/docs/commands/BeforeAll) - -[https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) +- [https://pester.dev/docs/commands/BeforeAll](https://pester.dev/docs/commands/BeforeAll) +- [https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/BeforeDiscovery.mdx b/docs/commands/BeforeDiscovery.mdx index 9da8056..d2d81af 100644 --- a/docs/commands/BeforeDiscovery.mdx +++ b/docs/commands/BeforeDiscovery.mdx @@ -23,7 +23,7 @@ Runs setup code that is used during Discovery phase. ## SYNTAX ```powershell -BeforeDiscovery [-ScriptBlock] [] +BeforeDiscovery [-ScriptBlock] ``` ## DESCRIPTION @@ -65,20 +65,28 @@ dynamically create a Describe-block and tests for each file found. The ScriptBlock to run. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -88,10 +96,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/BeforeDiscovery](https://pester.dev/docs/commands/BeforeDiscovery) - -[https://pester.dev/docs/usage/data-driven-tests](https://pester.dev/docs/usage/data-driven-tests) +- [https://pester.dev/docs/commands/BeforeDiscovery](https://pester.dev/docs/commands/BeforeDiscovery) +- [https://pester.dev/docs/usage/data-driven-tests](https://pester.dev/docs/usage/data-driven-tests) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/BeforeEach.mdx b/docs/commands/BeforeEach.mdx index a2f7f02..bfc9c64 100644 --- a/docs/commands/BeforeEach.mdx +++ b/docs/commands/BeforeEach.mdx @@ -24,7 +24,7 @@ the current Context or Describe block. ## SYNTAX ```powershell -BeforeEach [-Scriptblock] [] +BeforeEach [-Scriptblock] ``` ## DESCRIPTION @@ -72,20 +72,28 @@ The example uses BeforeEach to ensure a clean sample-file is used for each test. A scriptblock with steps to be executed during setup. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -95,10 +103,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/BeforeEach](https://pester.dev/docs/commands/BeforeEach) - -[https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) +- [https://pester.dev/docs/commands/BeforeEach](https://pester.dev/docs/commands/BeforeEach) +- [https://pester.dev/docs/usage/setup-and-teardown](https://pester.dev/docs/usage/setup-and-teardown) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Context.mdx b/docs/commands/Context.mdx index 11bb5b0..659db79 100644 --- a/docs/commands/Context.mdx +++ b/docs/commands/Context.mdx @@ -23,8 +23,8 @@ Provides logical grouping of It blocks within a single Describe block. ## SYNTAX ```powershell -Context [-Name] [-Tag ] [[-Fixture] ] [-Skip] [-AllowNullOrEmptyForEach] - [-ForEach ] [] +Context [-Name] [[-Fixture] ] [-Tag ] [-Skip] + [-AllowNullOrEmptyForEach] [-ForEach ] ``` ## DESCRIPTION @@ -69,40 +69,26 @@ Example of how to use Context for grouping different tests ## PARAMETERS -### -Name - -The name of the Context. -This is a phrase describing a set of tests within a describe. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Tag +### -AllowNullOrEmptyForEach -Optional parameter containing an array of strings. -When calling Invoke-Pester, -it is possible to specify a -Tag parameter which will only execute Context blocks -containing the same Tag. +Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. +This might be excepted in certain scenarios like using external data. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: Tags - -Required: False -Position: Named -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Fixture @@ -112,75 +98,123 @@ This may include setup specific to the context and one or more It blocks that validate the expected outcomes. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Skip +### -ForEach -Use this parameter to explicitly mark the block to be skipped. -This is preferable to temporarily -commenting out a block, because it remains listed in the output. +Allows data driven tests to be written. +Takes an array of data and generates one block for each item in the array, and makes the item +available as $_ in all child blocks. +When the array is an array of hashtables, it additionally +defines each key in the hashtable as variable. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AllowNullOrEmptyForEach +### -Name -Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. -This might be excepted in certain scenarios like using external data. +The name of the Context. +This is a phrase describing a set of tests within a describe. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Skip + +Use this parameter to explicitly mark the block to be skipped. +This is preferable to temporarily +commenting out a block, because it remains listed in the output. -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +```yaml +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ForEach +### -Tag -Allows data driven tests to be written. -Takes an array of data and generates one block for each item in the array, and makes the item -available as $_ in all child blocks. -When the array is an array of hashtables, it additionally -defines each key in the hashtable as variable. +Optional parameter containing an array of strings. +When calling Invoke-Pester, +it is possible to specify a -Tag parameter which will only execute Context blocks +containing the same Tag. ```yaml -Type: Object -Parameter Sets: (All) +Type: System.String[] +DefaultValue: '@()' +SupportsWildcards: false Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +- Tags +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -190,14 +224,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) - -[https://pester.dev/docs/usage/test-file-structure](https://pester.dev/docs/usage/test-file-structure) - -[https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) - -[https://pester.dev/docs/usage/testdrive](https://pester.dev/docs/usage/testdrive) +- [https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) +- [https://pester.dev/docs/usage/test-file-structure](https://pester.dev/docs/usage/test-file-structure) +- [https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) +- [https://pester.dev/docs/usage/testdrive](https://pester.dev/docs/usage/testdrive) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/ConvertTo-JUnitReport.mdx b/docs/commands/ConvertTo-JUnitReport.mdx index 5feff89..97d749c 100644 --- a/docs/commands/ConvertTo-JUnitReport.mdx +++ b/docs/commands/ConvertTo-JUnitReport.mdx @@ -23,7 +23,7 @@ Converts a Pester result-object to an JUnit-compatible XML report ## SYNTAX ```powershell -ConvertTo-JUnitReport [-Result] [-AsString] [] +ConvertTo-JUnitReport [-Result] [-AsString] ``` ## DESCRIPTION @@ -66,59 +66,74 @@ The returned object is a string. ## PARAMETERS -### -Result +### -AsString -Result object from a Pester-run. -This can be retrieved using Invoke-Pester --Passthru or by using the Run.PassThru configuration-option. +Returns the XML-report as a string. ```yaml -Type: Run -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AsString +### -Result -Returns the XML-report as a string. +Result object from a Pester-run. +This can be retrieved using Invoke-Pester +-Passthru or by using the Run.PassThru configuration-option. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: Pester.Run +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### Pester.Run + ## OUTPUTS ### System.Xml.XmlDocument ### System.String + ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/ConvertTo-JUnitReport](https://pester.dev/docs/commands/ConvertTo-JUnitReport) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/ConvertTo-JUnitReport](https://pester.dev/docs/commands/ConvertTo-JUnitReport) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/ConvertTo-NUnitReport.mdx b/docs/commands/ConvertTo-NUnitReport.mdx index 31a0d9c..e17e539 100644 --- a/docs/commands/ConvertTo-NUnitReport.mdx +++ b/docs/commands/ConvertTo-NUnitReport.mdx @@ -23,7 +23,7 @@ Converts a Pester result-object to an NUnit 2.5 or 3-compatible XML-report ## SYNTAX ```powershell -ConvertTo-NUnitReport [-Result] [-AsString] [[-Format] ] [] +ConvertTo-NUnitReport [-Result] [[-Format] ] [-AsString] ``` ## DESCRIPTION @@ -77,75 +77,95 @@ The returned object is a string. ## PARAMETERS -### -Result +### -AsString -Result object from a Pester-run. -This can be retrieved using Invoke-Pester --Passthru or by using the Run.PassThru configuration-option. +Returns the XML-report as a string. ```yaml -Type: Run -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AsString +### -Format -Returns the XML-report as a string. +Specifies the NUnit-schema to be used. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: NUnit2.5 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Format +### -Result -Specifies the NUnit-schema to be used. +Result object from a Pester-run. +This can be retrieved using Invoke-Pester +-Passthru or by using the Run.PassThru configuration-option. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: NUnit2.5 -Accept pipeline input: False -Accept wildcard characters: False +Type: Pester.Run +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### Pester.Run + ## OUTPUTS ### System.Xml.XmlDocument ### System.String + ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/ConvertTo-NUnitReport](https://pester.dev/docs/commands/ConvertTo-NUnitReport) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/ConvertTo-NUnitReport](https://pester.dev/docs/commands/ConvertTo-NUnitReport) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/ConvertTo-Pester4Result.mdx b/docs/commands/ConvertTo-Pester4Result.mdx index 2fcdcd9..a720534 100644 --- a/docs/commands/ConvertTo-Pester4Result.mdx +++ b/docs/commands/ConvertTo-Pester4Result.mdx @@ -23,7 +23,7 @@ Converts a Pester 5 result-object to an Pester 4-compatible object ## SYNTAX ```powershell -ConvertTo-Pester4Result [-PesterResult] [] +ConvertTo-Pester4Result [-PesterResult] ``` ## DESCRIPTION @@ -57,33 +57,42 @@ This can be retrieved using Invoke-Pester -Passthru or by using the Run.PassThru configuration-option. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/ConvertTo-Pester4Result](https://pester.dev/docs/commands/ConvertTo-Pester4Result) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/ConvertTo-Pester4Result](https://pester.dev/docs/commands/ConvertTo-Pester4Result) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Describe.mdx b/docs/commands/Describe.mdx index 51ebcfa..2bfa060 100644 --- a/docs/commands/Describe.mdx +++ b/docs/commands/Describe.mdx @@ -23,8 +23,8 @@ Creates a logical group of tests. ## SYNTAX ```powershell -Describe [-Name] [-Tag ] [[-Fixture] ] [-Skip] [-AllowNullOrEmptyForEach] - [-ForEach ] [] +Describe [-Name] [[-Fixture] ] [-Tag ] [-Skip] + [-AllowNullOrEmptyForEach] [-ForEach ] ``` ## DESCRIPTION @@ -32,8 +32,8 @@ Describe [-Name] [-Tag ] [[-Fixture] ] [-Skip] [ Creates a logical group of tests. All Mocks, TestDrive and TestRegistry contents defined within a Describe block are scoped to that Describe; they -will no longer be present when the Describe block exits. -A Describe +will no longer be present when the Describe block exits. + A Describe block may contain any number of Context and It blocks. ## EXAMPLES @@ -74,41 +74,26 @@ Using Describe to group tests logically at the root of the script/container ## PARAMETERS -### -Name - -The name of the test group. -This is often an expressive phrase describing -the scenario being tested. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Tag +### -AllowNullOrEmptyForEach -Optional parameter containing an array of strings. -When calling Invoke-Pester, -it is possible to specify a -Tag parameter which will only execute Describe blocks -containing the same Tag. +Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. +This might be excepted in certain scenarios like using external data. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: Tags - -Required: False -Position: Named -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Fixture @@ -122,75 +107,124 @@ Assertions are typically performed by the Should command within the It blocks. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Skip +### -ForEach -Use this parameter to explicitly mark the block to be skipped. -This is preferable to temporarily -commenting out a block, because it remains listed in the output. +Allows data driven tests to be written. +Takes an array of data and generates one block for each item in the array, and makes the item +available as $_ in all child blocks. +When the array is an array of hashtables, it additionally +defines each key in the hashtable as variable. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AllowNullOrEmptyForEach +### -Name -Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. -This might be excepted in certain scenarios like using external data. +The name of the test group. +This is often an expressive phrase describing +the scenario being tested. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Skip + +Use this parameter to explicitly mark the block to be skipped. +This is preferable to temporarily +commenting out a block, because it remains listed in the output. -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +```yaml +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ForEach +### -Tag -Allows data driven tests to be written. -Takes an array of data and generates one block for each item in the array, and makes the item -available as $_ in all child blocks. -When the array is an array of hashtables, it additionally -defines each key in the hashtable as variable. +Optional parameter containing an array of strings. +When calling Invoke-Pester, +it is possible to specify a -Tag parameter which will only execute Describe blocks +containing the same Tag. ```yaml -Type: Object -Parameter Sets: (All) +Type: System.String[] +DefaultValue: '@()' +SupportsWildcards: false Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +- Tags +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -200,14 +234,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) - -[https://pester.dev/docs/usage/test-file-structure](https://pester.dev/docs/usage/test-file-structure) - -[https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) - -[https://pester.dev/docs/usage/testdrive](https://pester.dev/docs/usage/testdrive) +- [https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) +- [https://pester.dev/docs/usage/test-file-structure](https://pester.dev/docs/usage/test-file-structure) +- [https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) +- [https://pester.dev/docs/usage/testdrive](https://pester.dev/docs/usage/testdrive) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Export-JUnitReport.mdx b/docs/commands/Export-JUnitReport.mdx index df9e382..4f0418a 100644 --- a/docs/commands/Export-JUnitReport.mdx +++ b/docs/commands/Export-JUnitReport.mdx @@ -23,7 +23,7 @@ Exports a Pester result-object to an JUnit-compatible XML-report ## SYNTAX ```powershell -Export-JUnitReport [-Result] [-Path] [] +Export-JUnitReport [-Result] [-Path] ``` ## DESCRIPTION @@ -53,56 +53,70 @@ exports it as an JUnit 4-compatible XML-report. ## PARAMETERS -### -Result +### -Path -Result object from a Pester-run. -This can be retrieved using Invoke-Pester --Passthru or by using the Run.PassThru configuration-option. +The path where the XML-report should be saved. ```yaml -Type: Run -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Path +### -Result -The path where the XML-report should be saved. +Result object from a Pester-run. +This can be retrieved using Invoke-Pester +-Passthru or by using the Run.PassThru configuration-option. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: Pester.Run +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### Pester.Run + ## OUTPUTS ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/Export-JUnitReport](https://pester.dev/docs/commands/Export-JUnitReport) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/Export-JUnitReport](https://pester.dev/docs/commands/Export-JUnitReport) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Export-NUnitReport.mdx b/docs/commands/Export-NUnitReport.mdx index 455bfdd..f253732 100644 --- a/docs/commands/Export-NUnitReport.mdx +++ b/docs/commands/Export-NUnitReport.mdx @@ -23,7 +23,7 @@ Exports a Pester result-object to an NUnit-compatible XML-report ## SYNTAX ```powershell -Export-NUnitReport [-Result] [-Path] [[-Format] ] [] +Export-NUnitReport [-Result] [-Path] [[-Format] ] ``` ## DESCRIPTION @@ -53,22 +53,25 @@ exports it as an NUnit 2.5-compatible XML-report. ## PARAMETERS -### -Result +### -Format -Result object from a Pester-run. -This can be retrieved using Invoke-Pester --Passthru or by using the Run.PassThru configuration-option. +Specifies the NUnit-schema to be used. ```yaml -Type: Run -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.String +DefaultValue: NUnit2.5 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Path @@ -76,49 +79,65 @@ Accept wildcard characters: False The path where the XML-report should be saved. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Format +### -Result -Specifies the NUnit-schema to be used. +Result object from a Pester-run. +This can be retrieved using Invoke-Pester +-Passthru or by using the Run.PassThru configuration-option. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: NUnit2.5 -Accept pipeline input: False -Accept wildcard characters: False +Type: Pester.Run +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### Pester.Run + ## OUTPUTS ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/Export-NUnitReport](https://pester.dev/docs/commands/Export-NUnitReport) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/Export-NUnitReport](https://pester.dev/docs/commands/Export-NUnitReport) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Get-ShouldOperator.mdx b/docs/commands/Get-ShouldOperator.mdx index 1e89c91..e7f4510 100644 --- a/docs/commands/Get-ShouldOperator.mdx +++ b/docs/commands/Get-ShouldOperator.mdx @@ -23,7 +23,7 @@ Display the assertion operators available for use with Should. ## SYNTAX ```powershell -Get-ShouldOperator [-Name ] [] +Get-ShouldOperator ``` ## DESCRIPTION @@ -60,20 +60,28 @@ Return help examples for the Be assertion operator. Name or alias of operator ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -88,10 +96,9 @@ standard PowerShell discovery patterns (like `Get-Help Should -Parameter *`). ## RELATED LINKS -[https://pester.dev/docs/commands/Get-ShouldOperator](https://pester.dev/docs/commands/Get-ShouldOperator) - -[https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) +- [https://pester.dev/docs/commands/Get-ShouldOperator](https://pester.dev/docs/commands/Get-ShouldOperator) +- [https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/InModuleScope.mdx b/docs/commands/InModuleScope.mdx index 3d745a7..fba5142 100644 --- a/docs/commands/InModuleScope.mdx +++ b/docs/commands/InModuleScope.mdx @@ -24,8 +24,8 @@ scope of a PowerShell script or manifest module. ## SYNTAX ```powershell -InModuleScope [-ModuleName] [-ScriptBlock] [[-Parameters] ] - [[-ArgumentList] ] [] +InModuleScope [-ModuleName] [-ScriptBlock] [[-Parameters] ] + [[-ArgumentList] ] ``` ## DESCRIPTION @@ -122,39 +122,49 @@ them in using `-Parameters` or `-ArgumentList`. ## PARAMETERS -### -ModuleName +### -ArgumentList -The name of the module into which the test code should be -injected. -This module must already be loaded into the current -PowerShell session. +A optional list of arguments to be passed to the scriptblock. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object[] +DefaultValue: '@()' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ScriptBlock +### -ModuleName -The code to be executed within the script or manifest module. +The name of the module into which the test code should be +injected. +This module must already be loaded into the current +PowerShell session. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Parameters @@ -163,36 +173,49 @@ A optional hashtable of parameters to be passed to the scriptblock. Parameters are automatically made available as variables in the scriptblock. ```yaml -Type: Hashtable -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: @{} -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Collections.Hashtable +DefaultValue: '@{}' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ArgumentList +### -ScriptBlock -A optional list of arguments to be passed to the scriptblock. +The code to be executed within the script or manifest module. ```yaml -Type: Object[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: 4 -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -202,8 +225,8 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/InModuleScope](https://pester.dev/docs/commands/InModuleScope) +- [https://pester.dev/docs/commands/InModuleScope](https://pester.dev/docs/commands/InModuleScope) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Invoke-Pester.mdx b/docs/commands/Invoke-Pester.mdx index f6a5002..42e3296 100644 --- a/docs/commands/Invoke-Pester.mdx +++ b/docs/commands/Invoke-Pester.mdx @@ -25,15 +25,15 @@ Runs Pester tests ### Simple (Default) ```powershell -Invoke-Pester [[-Path] ] [-ExcludePath ] [-TagFilter ] - [-ExcludeTagFilter ] [-FullNameFilter ] [-CI] [-Output ] [-PassThru] - [-Container ] [] +Invoke-Pester [[-Path] ] [-ExcludePath ] [-TagFilter ] + [-ExcludeTagFilter ] [-FullNameFilter ] [-CI] [-Output ] [-PassThru] + [-Container ] ``` ### Advanced ```powershell -Invoke-Pester [-Configuration ] [] +Invoke-Pester [-Configuration ] ``` ## DESCRIPTION @@ -121,58 +121,101 @@ to see other testresult options like output path and format and their default v ## PARAMETERS -### -Path +### -CI -Specifies one or more paths to files containing tests. -The value is a path\file -name or name pattern. -Wildcards are permitted. +Enable Test Results and Exit after Run. + +Equivalent to setting: + TestResult.Enabled = $true + Run.Exit = $true + +To also enable CodeCoverage use this configuration option: + CodeCoverage.Enabled = $true ```yaml -Type: String[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: 1 -Default value: . -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ExcludePath +### -Configuration -Specifies one or more paths to exclude from the test run. -Equivalent to ConfigurationProperty Run.ExcludePath. +[PesterConfiguration] object for Advanced Configuration created using `New-PesterConfiguration`. +For help on each option see about_PesterConfiguration or inspect the object. ```yaml -Type: String[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: PesterConfiguration +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Advanced + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -TagFilter +### -Container -Specifies tags to include in the test run. -Only tests with matching tags will run. -Equivalent to ConfigurationProperty Filter.Tag. +Specifies one or more ContainerInfo-objects that define containers with tests. +ContainerInfo-objects are generated using New-PesterContainer. +Useful for +scenarios where data-driven test are generated, e.g. +parametrized test files. ```yaml -Type: String[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: Pester.ContainerInfo[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -ExcludePath + +Specifies one or more paths to exclude from the test run. +Equivalent to ConfigurationProperty Run.ExcludePath. + +```yaml +Type: System.String[] +DefaultValue: '@()' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExcludeTagFilter @@ -181,15 +224,20 @@ Specifies tags to exclude from the test run. Equivalent to ConfigurationProperty Filter.ExcludeTag. ```yaml -Type: String[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FullNameFilter @@ -198,38 +246,20 @@ Specifies test full names (including Describe/Context/It path) to run. Equivalent to ConfigurationProperty Filter.FullName. ```yaml -Type: String[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -CI - -Enable Test Results and Exit after Run. - -Equivalent to setting: - TestResult.Enabled = $true - Run.Exit = $true - -To also enable CodeCoverage use this configuration option: - CodeCoverage.Enabled = $true - -```yaml -Type: SwitchParameter -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Output @@ -241,15 +271,20 @@ Equivalent to ConfigurationProperty Output.Verbosity. Default value is: Normal ```yaml -Type: String -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: Normal -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: Normal +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -PassThru @@ -262,57 +297,75 @@ Equivalent to ConfigurationProperty Run.PassThru. To suppress the host output, use the Output parameter with value None. ```yaml -Type: SwitchParameter -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Container +### -Path -Specifies one or more ContainerInfo-objects that define containers with tests. -ContainerInfo-objects are generated using New-PesterContainer. -Useful for -scenarios where data-driven test are generated, e.g. -parametrized test files. +Specifies one or more paths to files containing tests. +The value is a path\file +name or name pattern. +Wildcards are permitted. ```yaml -Type: ContainerInfo[] -Parameter Sets: Simple -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: . +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Configuration +### -TagFilter -[PesterConfiguration] object for Advanced Configuration created using `New-PesterConfiguration`. -For help on each option see about_PesterConfiguration or inspect the object. +Specifies tags to include in the test run. +Only tests with matching tags will run. +Equivalent to ConfigurationProperty Filter.Tag. ```yaml -Type: PesterConfiguration -Parameter Sets: Advanced -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Simple + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -324,10 +377,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) - -[https://pester.dev/docs/quick-start](https://pester.dev/docs/quick-start) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/quick-start](https://pester.dev/docs/quick-start) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/It.mdx b/docs/commands/It.mdx index 0c39ed4..cb8eaf0 100644 --- a/docs/commands/It.mdx +++ b/docs/commands/It.mdx @@ -25,15 +25,15 @@ Validates the results of a test inside of a Describe block. ### Normal (Default) ```powershell -It [-Name] [[-Test] ] [-ForEach ] [-Tag ] [-AllowNullOrEmptyForEach] - [] +It [-Name] [[-Test] ] [-ForEach ] [-Tag ] + [-AllowNullOrEmptyForEach] ``` ### Skip ```powershell -It [-Name] [[-Test] ] [-ForEach ] [-Tag ] [-Skip] - [-AllowNullOrEmptyForEach] [] +It [-Name] [[-Test] ] [-ForEach ] [-Tag ] [-Skip] + [-AllowNullOrEmptyForEach] ``` ## DESCRIPTION @@ -121,79 +121,75 @@ current hashtable are made available as variables inside It. ## PARAMETERS -### -Name - -An expressive phrase describing the expected test outcome. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Test +### -AllowNullOrEmptyForEach -The script block that should throw an exception if the -expectation of the test is not met.If you are following the -AAA pattern (Arrange-Act-Assert), this typically holds the -Assert. +Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. +This might be excepted in certain scenarios like using external data. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ForEach (Formerly called TestCases.) Optional array of hashtable (or any IDictionary) objects. If this parameter is used, Pester will call the test script block once for each table in -the ForEach array, splatting the dictionary to the test script block as input. -If you want +the ForEach array, splatting the dictionary to the test script block as input. + If you want the name of the test to appear differently for each test case, you can embed tokens into the Name parameter with the syntax 'Adds numbers <A> and <B>' (assuming you have keys named A and B in your ForEach hashtables.) ```yaml -Type: Object[] -Parameter Sets: (All) -Aliases: TestCases - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object[] +DefaultValue: '' +SupportsWildcards: false +Aliases: +- TestCases +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Tag +### -Name -Optional parameter containing an array of strings. -When calling Invoke-Pester, -it is possible to include or exclude tests containing the same Tag. +An expressive phrase describing the expected test outcome. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Skip @@ -203,37 +199,75 @@ This is preferable to temporarily commenting out a test, because the test remains listed in the output. ```yaml -Type: SwitchParameter -Parameter Sets: Skip -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Skip + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AllowNullOrEmptyForEach +### -Tag -Allows empty or null values for -ForEach when Run.FailOnNullOrEmptyForEach is enabled. -This might be excepted in certain scenarios like using external data. +Optional parameter containing an array of strings. +When calling Invoke-Pester, +it is possible to include or exclude tests containing the same Tag. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Test + +The script block that should throw an exception if the +expectation of the test is not met.If you are following the +AAA pattern (Arrange-Act-Assert), this typically holds the +Assert. -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +```yaml +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -243,14 +277,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/It](https://pester.dev/docs/commands/It) - -[https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) - -[https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) - -[https://pester.dev/docs/commands/Set-ItResult](https://pester.dev/docs/commands/Set-ItResult) +- [https://pester.dev/docs/commands/It](https://pester.dev/docs/commands/It) +- [https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) +- [https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) +- [https://pester.dev/docs/commands/Set-ItResult](https://pester.dev/docs/commands/Set-ItResult) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Mock.mdx b/docs/commands/Mock.mdx index d374d3a..adee258 100644 --- a/docs/commands/Mock.mdx +++ b/docs/commands/Mock.mdx @@ -24,9 +24,9 @@ implementation. ## SYNTAX ```powershell -Mock [[-CommandName] ] [[-MockWith] ] [-Verifiable] [[-ParameterFilter] ] - [[-ModuleName] ] [[-RemoveParameterType] ] [[-RemoveParameterValidation] ] - [] +Mock [[-CommandName] ] [[-MockWith] ] [[-ParameterFilter] ] + [[-ModuleName] ] [[-RemoveParameterType] ] + [[-RemoveParameterValidation] ] [-Verifiable] ``` ## DESCRIPTION @@ -190,15 +190,20 @@ mocked by using the -ModuleName parameter. The name of the command to be mocked. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -MockWith @@ -211,32 +216,45 @@ being mocked, and the MockWith script block can contain references to the mocked commands parameter variables. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: {} -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '{}' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Verifiable +### -ModuleName -When this is set, the mock will be checked when Should -InvokeVerifiable is -called. +Optional string specifying the name of the module where this command +is to be mocked. + This should be a module that _calls_ the mocked +command; it doesn't necessarily have to be the same module which +originally implemented the command. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ParameterFilter @@ -249,35 +267,20 @@ This ScriptBlock must return a boolean value. See examples for usage. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -ModuleName - -Optional string specifying the name of the module where this command -is to be mocked. -This should be a module that _calls_ the mocked -command; it doesn't necessarily have to be the same module which -originally implemented the command. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 4 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -RemoveParameterType @@ -289,15 +292,20 @@ type requirements and allows some strongly typed functions to be mocked more easily. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: 5 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 4 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -RemoveParameterValidation @@ -309,20 +317,50 @@ validation requirements, and allows functions that are strict about their parameter validation to be mocked more easily. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: 6 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 5 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Verifiable + +When this is set, the mock will be checked when Should -InvokeVerifiable is +called. + +```yaml +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -332,10 +370,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Mock](https://pester.dev/docs/commands/Mock) - -[https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) +- [https://pester.dev/docs/commands/Mock](https://pester.dev/docs/commands/Mock) +- [https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/New-Fixture.mdx b/docs/commands/New-Fixture.mdx index 02de35b..7445a92 100644 --- a/docs/commands/New-Fixture.mdx +++ b/docs/commands/New-Fixture.mdx @@ -24,7 +24,7 @@ and another one that contains its tests. ## SYNTAX ```powershell -New-Fixture [-Name] [[-Path] ] [] +New-Fixture [-Name] [[-Path] ] ``` ## DESCRIPTION @@ -90,15 +90,20 @@ Creates a new folder named Cleaner in the current directory and creates the scri Defines the name of the function and the name of the test to be created. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Path @@ -107,20 +112,28 @@ Defines path where the test and the function should be created, you can use full If the parameter is not specified the scripts are created in the current directory. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: $PWD -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: $PWD +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -132,16 +145,12 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/New-Fixture](https://pester.dev/docs/commands/New-Fixture) - -[https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) - -[https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) - -[https://pester.dev/docs/commands/It](https://pester.dev/docs/commands/It) - -[https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) +- [https://pester.dev/docs/commands/New-Fixture](https://pester.dev/docs/commands/New-Fixture) +- [https://pester.dev/docs/commands/Describe](https://pester.dev/docs/commands/Describe) +- [https://pester.dev/docs/commands/Context](https://pester.dev/docs/commands/Context) +- [https://pester.dev/docs/commands/It](https://pester.dev/docs/commands/It) +- [https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/New-MockObject.mdx b/docs/commands/New-MockObject.mdx index 49fafb6..84e2730 100644 --- a/docs/commands/New-MockObject.mdx +++ b/docs/commands/New-MockObject.mdx @@ -25,15 +25,15 @@ This function instantiates a .NET object from a type. ### Type (Default) ```powershell -New-MockObject [-Type] [-Properties ] [-Methods ] [-MethodHistoryPrefix ] - [] +New-MockObject [-Type] [-Properties ] [-Methods ] + [-MethodHistoryPrefix ] ``` ### InputObject ```powershell -New-MockObject -InputObject [-Properties ] [-Methods ] - [-MethodHistoryPrefix ] [] +New-MockObject -InputObject [-Properties ] [-Methods ] + [-MethodHistoryPrefix ] ``` ## DESCRIPTION @@ -101,61 +101,53 @@ to mock output using an internal module class. ## PARAMETERS -### -Type - -The .NET type to create. -This creates the object without calling any of its constructors or initializers. -Use this to instantiate an object that does not have a public constructor. -If your object has a constructor, or is giving you errors, try using the constructor and provide the object using the InputObject parameter to decorate it. - -```yaml -Type: Type -Parameter Sets: Type -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - ### -InputObject An already constructed object to decorate. Use `New-Object` or `[typeName]::new()` to create it. ```yaml -Type: Object -Parameter Sets: InputObject -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: InputObject + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Properties +### -MethodHistoryPrefix -Properties to define, specified as a hashtable, in format `@\{ PropertyName = value \}`. +Prefix for the history-property created for each mocked method. +Default is '_' which would create the property '_MethodName'. ```yaml -Type: Hashtable -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: _ +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Methods -Methods to define, specified as a hashtable, in format `@\{ MethodName = scriptBlock \}`. +Methods to define, specified as a hashtable, in format `@{ MethodName = scriptBlock }`. ScriptBlock can define param block, and it will receive arguments that were provided to the function call based on order. @@ -164,37 +156,85 @@ Method overloads are not supported because ScriptMethods are used to decorate th For each method a property named `_MethodName` (if using default `-MethodHistoryPrefix`) is defined which holds history of the invocations of the method and the arguments that were provided. ```yaml -Type: Hashtable -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Collections.Hashtable +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: InputObject + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Type + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -MethodHistoryPrefix +### -Properties -Prefix for the history-property created for each mocked method. -Default is '_' which would create the property '_MethodName'. +Properties to define, specified as a hashtable, in format `@{ PropertyName = value }`. + +```yaml +Type: System.Collections.Hashtable +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: InputObject + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Type + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Type + +The .NET type to create. +This creates the object without calling any of its constructors or initializers. +Use this to instantiate an object that does not have a public constructor. +If your object has a constructor, or is giving you errors, try using the constructor and provide the object using the InputObject parameter to decorate it. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: _ -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Type +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Type + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -204,10 +244,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/New-MockObject](https://pester.dev/docs/commands/New-MockObject) - -[https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) +- [https://pester.dev/docs/commands/New-MockObject](https://pester.dev/docs/commands/New-MockObject) +- [https://pester.dev/docs/usage/mocking](https://pester.dev/docs/usage/mocking) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/New-PesterConfiguration.mdx b/docs/commands/New-PesterConfiguration.mdx index dae3d2c..ff78ccc 100644 --- a/docs/commands/New-PesterConfiguration.mdx +++ b/docs/commands/New-PesterConfiguration.mdx @@ -23,7 +23,7 @@ Creates a new PesterConfiguration object for advanced configuration of Invoke-Pe ## SYNTAX ```powershell -New-PesterConfiguration [[-Hashtable] ] [] +New-PesterConfiguration [[-Hashtable] ] ``` ## DESCRIPTION @@ -88,20 +88,28 @@ See about_PesterConfiguration help topic or inspect a PesterConfiguration-object available options. ```yaml -Type: IDictionary -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Collections.IDictionary +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -113,12 +121,10 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/New-PesterConfiguration](https://pester.dev/docs/commands/New-PesterConfiguration) - -[https://pester.dev/docs/usage/Configuration](https://pester.dev/docs/usage/Configuration) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/commands/New-PesterConfiguration](https://pester.dev/docs/commands/New-PesterConfiguration) +- [https://pester.dev/docs/usage/Configuration](https://pester.dev/docs/usage/Configuration) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/New-PesterContainer.mdx b/docs/commands/New-PesterContainer.mdx index e73b380..c234b1f 100644 --- a/docs/commands/New-PesterContainer.mdx +++ b/docs/commands/New-PesterContainer.mdx @@ -25,13 +25,13 @@ Generates ContainerInfo-objects used as for Invoke-Pester -Container ### Path (Default) ```powershell -New-PesterContainer -Path [-Data ] [] +New-PesterContainer -Path [-Data ] ``` ### ScriptBlock ```powershell -New-PesterContainer -ScriptBlock [-Data ] [] +New-PesterContainer -ScriptBlock [-Data ] ``` ## DESCRIPTION @@ -80,6 +80,28 @@ the required ContainerInfo-object that enables us to do this directly. ## PARAMETERS +### -Data + +Allows a dictionary to be provided with parameter-values that should be used during +execution of the test containers defined in Path or ScriptBlock. + +```yaml +Type: System.Collections.IDictionary[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + ### -Path Specifies one or more paths to files containing tests. @@ -88,15 +110,20 @@ name or name pattern. Wildcards are permitted. ```yaml -Type: String[] -Parameter Sets: Path -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Path + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ScriptBlock @@ -104,37 +131,28 @@ Accept wildcard characters: False Specifies one or more scriptblocks containing tests. ```yaml -Type: ScriptBlock[] -Parameter Sets: ScriptBlock -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Data - -Allows a dictionary to be provided with parameter-values that should be used during -execution of the test containers defined in Path or ScriptBlock. - -```yaml -Type: IDictionary[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: ScriptBlock + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -146,12 +164,10 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/New-PesterContainer](https://pester.dev/docs/commands/New-PesterContainer) - -[https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) - -[https://pester.dev/docs/usage/data-driven-tests](https://pester.dev/docs/usage/data-driven-tests) +- [https://pester.dev/docs/commands/New-PesterContainer](https://pester.dev/docs/commands/New-PesterContainer) +- [https://pester.dev/docs/commands/Invoke-Pester](https://pester.dev/docs/commands/Invoke-Pester) +- [https://pester.dev/docs/usage/data-driven-tests](https://pester.dev/docs/usage/data-driven-tests) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Set-ItResult.mdx b/docs/commands/Set-ItResult.mdx index eaedd12..f674cf8 100644 --- a/docs/commands/Set-ItResult.mdx +++ b/docs/commands/Set-ItResult.mdx @@ -25,13 +25,13 @@ Set-ItResult is used inside the It block to explicitly set the test result ### Inconclusive ```powershell -Set-ItResult [-Inconclusive] [-Because ] [] +Set-ItResult [-Inconclusive] [-Because ] ``` ### Skipped ```powershell -Set-ItResult [-Skipped] [-Because ] [] +Set-ItResult [-Skipped] [-Because ] ``` ## DESCRIPTION @@ -58,7 +58,7 @@ Describe "Example" { the output should be -```powershell +``` Describing Example [?] Inconclusive test is inconclusive, because we want it to be inconclusive 35ms [!] Skipped test is skipped, because we want it to be skipped 3ms @@ -68,21 +68,49 @@ Tests Passed: 0, Failed: 0, Skipped: 1, Inconclusive: 1, NotRun: 0 ## PARAMETERS +### -Because + +Similarly to failing tests, skipped and inconclusive tests should have reason. +It allows +to provide information to the user why the test is neither successful nor failed. + +```yaml +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + ### -Inconclusive Sets the test result to inconclusive. Cannot be used at the same time as -Skipped ```yaml -Type: SwitchParameter -Parameter Sets: Inconclusive -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Inconclusive + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Skipped @@ -91,38 +119,28 @@ Sets the test result to skipped. Cannot be used at the same time as -Inconclusive. ```yaml -Type: SwitchParameter -Parameter Sets: Skipped -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Because - -Similarly to failing tests, skipped and inconclusive tests should have reason. -It allows -to provide information to the user why the test is neither successful nor failed. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Skipped + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -132,8 +150,8 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## RELATED LINKS -[https://pester.dev/docs/commands/Set-ItResult](https://pester.dev/docs/commands/Set-ItResult) +- [https://pester.dev/docs/commands/Set-ItResult](https://pester.dev/docs/commands/Set-ItResult) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-All.mdx b/docs/commands/Should-All.mdx index c9c8126..d3bc82a 100644 --- a/docs/commands/Should-All.mdx +++ b/docs/commands/Should-All.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares all items in a collection to a filter script. -If the filter returns true, or does not throw for all the items in the collection, the assertion passes. +Compares all items in a collection to a filter script. If the filter returns true, or does not throw for all the items in the collection, the assertion passes. ## SYNTAX ```powershell -Should-All [[-Actual] ] [-FilterScript] [-Because ] [] +Should-All [-FilterScript] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -59,56 +58,76 @@ The assertions will fail because not all items in the array are greater than 1. A collection of items to filter. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -FilterScript +### -Because -A script block that filters the input collection. -The script block can use Should-* assertions or throw exceptions to indicate failure. +The reason why the input should be the expected value. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -FilterScript -The reason why the input should be the expected value. +A script block that filters the input collection. +The script block can use Should-* assertions or throw exceptions to indicate failure. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -121,10 +140,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-All](https://pester.dev/docs/commands/Should-All) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-All](https://pester.dev/docs/commands/Should-All) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-Any.mdx b/docs/commands/Should-Any.mdx index 6dd665d..fa4743b 100644 --- a/docs/commands/Should-Any.mdx +++ b/docs/commands/Should-Any.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares all items in a collection to a filter script. -If the filter returns true, or does not throw for any of the items in the collection, the assertion passes. +Compares all items in a collection to a filter script. If the filter returns true, or does not throw for any of the items in the collection, the assertion passes. ## SYNTAX ```powershell -Should-Any [[-Actual] ] [-FilterScript] [-Because ] [] +Should-Any [-FilterScript] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -60,56 +59,76 @@ The assertions will fail because none of theitems in the array are greater than A collection of items to filter. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -FilterScript +### -Because -A script block that filters the input collection. -The script block can use Should-* assertions or throw exceptions to indicate failure. +The reason why the input should be the expected value. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -FilterScript -The reason why the input should be the expected value. +A script block that filters the input collection. +The script block can use Should-* assertions or throw exceptions to indicate failure. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -122,10 +141,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-Any](https://pester.dev/docs/commands/Should-Any) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-Any](https://pester.dev/docs/commands/Should-Any) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-Be.mdx b/docs/commands/Should-Be.mdx index b7ffb3a..84cc230 100644 --- a/docs/commands/Should-Be.mdx +++ b/docs/commands/Should-Be.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if they are equal. ## SYNTAX ```powershell -Should-Be [[-Actual] ] [-Expected] [-Because ] [] +Should-Be [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -49,55 +49,75 @@ These assertions will pass, because the expected value is equal to the actual va The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -110,10 +130,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-Be](https://pester.dev/docs/commands/Should-Be) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-Be](https://pester.dev/docs/commands/Should-Be) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeAfter.mdx b/docs/commands/Should-BeAfter.mdx index 9785646..a7b7327 100644 --- a/docs/commands/Should-BeAfter.mdx +++ b/docs/commands/Should-BeAfter.mdx @@ -25,25 +25,25 @@ Asserts that the provided [datetime] is after the expected [datetime]. ### Now (Default) ```powershell -Should-BeAfter [[-Actual] ] [-Now] [-Because ] [] +Should-BeAfter [[-Actual] ] [-Now] [-Because ] ``` ### FluentFromNow ```powershell -Should-BeAfter [[-Actual] ] [[-Time] ] [-FromNow] [-Because ] [] +Should-BeAfter [[-Time] ] [[-Actual] ] -FromNow [-Because ] ``` ### FluentAgo ```powershell -Should-BeAfter [[-Actual] ] [[-Time] ] [-Ago] [-Because ] [] +Should-BeAfter [[-Time] ] [[-Actual] ] -Ago [-Because ] ``` ### Expected ```powershell -Should-BeAfter [[-Actual] ] [[-Expected] ] [-Because ] [] +Should-BeAfter [[-Expected] ] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -92,65 +92,83 @@ This assertion will pass, because the actual value is after the expected value. The actual [datetime] value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Now +### -Ago -Indicates that the current time should be used as the expected time. +Indicates that the -Time should be subtracted from the current time. ```yaml -Type: SwitchParameter -Parameter Sets: Now -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentAgo + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Time +### -Because -The time to add or subtract from the current time. -This parameter uses fluent time syntax e.g. -1minute. +The reason why the actual value should be after the expected value. ```yaml -Type: String -Parameter Sets: FluentFromNow, FluentAgo -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Ago +### -Expected -Indicates that the -Time should be subtracted from the current time. +The expected [datetime] value. ```yaml -Type: SwitchParameter -Parameter Sets: FluentAgo -Aliases: - -Required: True -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.DateTime +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Expected + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FromNow @@ -158,55 +176,83 @@ Accept wildcard characters: False Indicates that the -Time should be added to the current time. ```yaml -Type: SwitchParameter -Parameter Sets: FluentFromNow -Aliases: - -Required: True -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentFromNow + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Now -The expected [datetime] value. +Indicates that the current time should be used as the expected time. ```yaml -Type: DateTime -Parameter Sets: Expected -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Now + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Time -The reason why the actual value should be after the expected value. +The time to add or subtract from the current time. +This parameter uses fluent time syntax e.g. +1minute. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentFromNow + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FluentAgo + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -221,10 +267,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeAfter](https://pester.dev/docs/commands/Should-BeAfter) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeAfter](https://pester.dev/docs/commands/Should-BeAfter) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeBefore.mdx b/docs/commands/Should-BeBefore.mdx index ad383d6..a44fc34 100644 --- a/docs/commands/Should-BeBefore.mdx +++ b/docs/commands/Should-BeBefore.mdx @@ -25,25 +25,25 @@ Asserts that the provided [datetime] is before the expected [datetime]. ### Now (Default) ```powershell -Should-BeBefore [[-Actual] ] [-Now] [-Because ] [] +Should-BeBefore [[-Actual] ] [-Now] [-Because ] ``` ### FluentFromNow ```powershell -Should-BeBefore [[-Actual] ] [[-Time] ] [-FromNow] [-Because ] [] +Should-BeBefore [[-Time] ] [[-Actual] ] -FromNow [-Because ] ``` ### FluentAgo ```powershell -Should-BeBefore [[-Actual] ] [[-Time] ] [-Ago] [-Because ] [] +Should-BeBefore [[-Time] ] [[-Actual] ] -Ago [-Because ] ``` ### Expected ```powershell -Should-BeBefore [[-Actual] ] [[-Expected] ] [-Because ] [] +Should-BeBefore [[-Expected] ] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -92,65 +92,83 @@ This assertion will pass, because the actual value is before the expected value. The actual [datetime] value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Now +### -Ago -Indicates that the current time should be used as the expected time. +Indicates that the -Time should be subtracted from the current time. ```yaml -Type: SwitchParameter -Parameter Sets: Now -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentAgo + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Time +### -Because -The time to add or subtract from the current time. -This parameter uses fluent time syntax e.g. -1minute. +The reason why the actual value should be before the expected value. ```yaml -Type: String -Parameter Sets: FluentFromNow, FluentAgo -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Ago +### -Expected -Indicates that the -Time should be subtracted from the current time. +The expected [datetime] value. ```yaml -Type: SwitchParameter -Parameter Sets: FluentAgo -Aliases: - -Required: True -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.DateTime +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Expected + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FromNow @@ -158,55 +176,83 @@ Accept wildcard characters: False Indicates that the -Time should be added to the current time. ```yaml -Type: SwitchParameter -Parameter Sets: FluentFromNow -Aliases: - -Required: True -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentFromNow + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Now -The expected [datetime] value. +Indicates that the current time should be used as the expected time. ```yaml -Type: DateTime -Parameter Sets: Expected -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Now + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Time -The reason why the actual value should be before the expected value. +The time to add or subtract from the current time. +This parameter uses fluent time syntax e.g. +1minute. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FluentFromNow + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FluentAgo + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -221,10 +267,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeBefore](https://pester.dev/docs/commands/Should-BeBefore) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeBefore](https://pester.dev/docs/commands/Should-BeBefore) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeCollection.mdx b/docs/commands/Should-BeCollection.mdx index d5b3eac..4846453 100644 --- a/docs/commands/Should-BeCollection.mdx +++ b/docs/commands/Should-BeCollection.mdx @@ -18,21 +18,20 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares collections for equality, by comparing their sizes and each item in them. -It does not compare the types of the input collections. +Compares collections for equality, by comparing their sizes and each item in them. It does not compare the types of the input collections. ## SYNTAX ### Expected ```powershell -Should-BeCollection [[-Actual] ] [-Expected] [-Because ] [] +Should-BeCollection [-Expected] [[-Actual] ] [-Because ] ``` ### Count ```powershell -Should-BeCollection [[-Actual] ] [-Because ] [-Count ] [] +Should-BeCollection [[-Actual] ] [-Because ] [-Count ] ``` ## DESCRIPTION @@ -70,71 +69,96 @@ The assertions will fail because the collections are not equal. A collection of items. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -A collection of items. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: Expected -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Count -The reason why the input should be the expected value. +Checks if the collection has the expected number of items. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Int32 +DefaultValue: 0 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Count + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Count +### -Expected -Checks if the collection has the expected number of items. +A collection of items. ```yaml -Type: Int32 -Parameter Sets: Count -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Expected + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -147,10 +171,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeCollection](https://pester.dev/docs/commands/Should-BeCollection) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeCollection](https://pester.dev/docs/commands/Should-BeCollection) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeEmptyString.mdx b/docs/commands/Should-BeEmptyString.mdx index 9a6512a..78e1177 100644 --- a/docs/commands/Should-BeEmptyString.mdx +++ b/docs/commands/Should-BeEmptyString.mdx @@ -23,7 +23,7 @@ Ensures that input is an empty string. ## SYNTAX ```powershell -Should-BeEmptyString [[-Actual] ] [-Because ] [] +Should-BeEmptyString [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -69,15 +69,20 @@ All the tests above will fail, the input is not a string. The actual value that will be compared to an empty string. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -85,23 +90,33 @@ Accept wildcard characters: False The reason why the input should be an empty string. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -114,10 +129,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeEmptyString](https://pester.dev/docs/commands/Should-BeEmptyString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeEmptyString](https://pester.dev/docs/commands/Should-BeEmptyString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeEquivalent.mdx b/docs/commands/Should-BeEquivalent.mdx index 0221f46..36aab66 100644 --- a/docs/commands/Should-BeEquivalent.mdx +++ b/docs/commands/Should-BeEquivalent.mdx @@ -23,8 +23,8 @@ Compares two objects for equivalency, by recursively comparing their properties ## SYNTAX ```powershell -Should-BeEquivalent [[-Actual] ] [-Expected] [-Because ] [-ExcludePath ] - [-ExcludePathsNotOnExpected] [-Comparator ] [] +Should-BeEquivalent [-Expected] [[-Actual] ] [-Because ] + [-ExcludePath ] [-ExcludePathsNotOnExpected] [-Comparator ] ``` ## DESCRIPTION @@ -45,8 +45,10 @@ This example generates an equivalency option object that excludes the 'Id' and ' ### EXAMPLE 2 ```powershell +```powereshell Should-BeEquivalent ... -ExcludePathsNotOnExpected ``` +``` This example generates an equivalency option object that excludes any paths not present on the expected object from the comparison, using the default deep comparison strategy. @@ -90,47 +92,64 @@ This will pass because the actual object has the same properties as the expected The actual object to compare. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected object to compare. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Comparator -The reason why the input should be the expected value. +Specifies the comparison strategy to use. +The options are 'Equivalency' for a deep comparison that considers the structure and values of objects, and 'Equality' for a simple equality comparison. +The default is 'Equivalency'. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: Equivalency +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExcludePath @@ -140,15 +159,20 @@ Each path should correspond to a property name or a chain of property names sepa The paths use dot notation to navigate to a child property, such as "user.name". ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: @() -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '@()' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExcludePathsNotOnExpected @@ -157,41 +181,54 @@ A switch parameter that, when set, excludes any paths from the comparison that a This is useful for ignoring extra properties on the actual object that are not relevant to the comparison. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Comparator +### -Expected -Specifies the comparison strategy to use. -The options are 'Equivalency' for a deep comparison that considers the structure and values of objects, and 'Equality' for a simple equality comparison. -The default is 'Equivalency'. +The expected object to compare. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: Equivalency -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -204,10 +241,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeEquivalent](https://pester.dev/docs/commands/Should-BeEquivalent) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeEquivalent](https://pester.dev/docs/commands/Should-BeEquivalent) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeFalse.mdx b/docs/commands/Should-BeFalse.mdx index f5e7b7f..d1049cb 100644 --- a/docs/commands/Should-BeFalse.mdx +++ b/docs/commands/Should-BeFalse.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares the actual value to a boolean $false. -It does not convert input values to boolean, and will fail for any value that is not $false. +Compares the actual value to a boolean $false. It does not convert input values to boolean, and will fail for any value that is not $false. ## SYNTAX ```powershell -Should-BeFalse [[-Actual] ] [[-Because] ] [] +Should-BeFalse [[-Actual] ] [[-Because] ] ``` ## DESCRIPTION @@ -62,15 +61,20 @@ All of these assertions will fail, because the actual value is not $false. The actual value to compare to $false. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -78,23 +82,33 @@ Accept wildcard characters: False The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +123,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeFalse](https://pester.dev/docs/commands/Should-BeFalse) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeFalse](https://pester.dev/docs/commands/Should-BeFalse) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeFalsy.mdx b/docs/commands/Should-BeFalsy.mdx index 3e6dae4..9a1c31b 100644 --- a/docs/commands/Should-BeFalsy.mdx +++ b/docs/commands/Should-BeFalsy.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares the actual value to a boolean $false or a falsy value: 0, "", $null or @(). -It converts the input value to a boolean. +Compares the actual value to a boolean $false or a falsy value: 0, "", $null or @(). It converts the input value to a boolean. ## SYNTAX ```powershell -Should-BeFalsy [[-Actual] ] [[-Because] ] [] +Should-BeFalsy [[-Actual] ] [[-Because] ] ``` ## DESCRIPTION @@ -62,15 +61,20 @@ These assertions will fail, because the actual value is not $false or falsy. The actual value to compare to $false. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -78,23 +82,33 @@ Accept wildcard characters: False The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +123,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeFalsy](https://pester.dev/docs/commands/Should-BeFalsy) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeFalsy](https://pester.dev/docs/commands/Should-BeFalsy) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeFasterThan.mdx b/docs/commands/Should-BeFasterThan.mdx index e2c4bc9..150a278 100644 --- a/docs/commands/Should-BeFasterThan.mdx +++ b/docs/commands/Should-BeFasterThan.mdx @@ -23,7 +23,7 @@ Asserts that the provided [timespan] or [scriptblock] is faster than the expecte ## SYNTAX ```powershell -Should-BeFasterThan [[-Actual] ] [[-Expected] ] [-Because ] [] +Should-BeFasterThan [[-Expected] ] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -56,55 +56,75 @@ This assertion will fail, because the actual value is not faster than the expect The actual [timespan] or [scriptblock] value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected [timespan] or fluent time value. +The reason why the actual value should be faster than the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should be faster than the expected value. +The expected [timespan] or fluent time value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -119,10 +139,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeFasterThan](https://pester.dev/docs/commands/Should-BeFasterThan) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeFasterThan](https://pester.dev/docs/commands/Should-BeFasterThan) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeGreaterThan.mdx b/docs/commands/Should-BeGreaterThan.mdx index bdddb0a..52d36fb 100644 --- a/docs/commands/Should-BeGreaterThan.mdx +++ b/docs/commands/Should-BeGreaterThan.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if the actual value is great ## SYNTAX ```powershell -Should-BeGreaterThan [[-Actual] ] [-Expected] [-Because ] [] +Should-BeGreaterThan [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -48,55 +48,75 @@ These assertions will pass, because the actual value is greater than the expecte The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +129,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeGreaterThan](https://pester.dev/docs/commands/Should-BeGreaterThan) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeGreaterThan](https://pester.dev/docs/commands/Should-BeGreaterThan) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeGreaterThanOrEqual.mdx b/docs/commands/Should-BeGreaterThanOrEqual.mdx index f696c92..ef63714 100644 --- a/docs/commands/Should-BeGreaterThanOrEqual.mdx +++ b/docs/commands/Should-BeGreaterThanOrEqual.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if the actual value is great ## SYNTAX ```powershell -Should-BeGreaterThanOrEqual [[-Actual] ] [-Expected] [-Because ] [] +Should-BeGreaterThanOrEqual [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -48,55 +48,75 @@ These assertions will pass, because the actual value is greater than or equal to The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +129,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeGreaterThanOrEqual](https://pester.dev/docs/commands/Should-BeGreaterThanOrEqual) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeGreaterThanOrEqual](https://pester.dev/docs/commands/Should-BeGreaterThanOrEqual) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeHashtable.mdx b/docs/commands/Should-BeHashtable.mdx index aad1b61..64e9943 100644 --- a/docs/commands/Should-BeHashtable.mdx +++ b/docs/commands/Should-BeHashtable.mdx @@ -24,23 +24,23 @@ entries, whether it is ordered, and that it contains specific keys. ## SYNTAX ```powershell -Should-BeHashtable [[-Actual] ] [-Count ] [-Key ] [-Ordered] [-Because ] - [] +Should-BeHashtable [[-Actual] ] [-Count ] [-Key ] [-Ordered] + [-Because ] ``` ## DESCRIPTION `Should-BeHashtable` is a shape assertion. It verifies that `$Actual` is a hashtable or -dictionary (anything implementing `System.Collections.IDictionary`, such as `@\{\}`, -`[ordered]@\{\}` or a generic `Dictionary[,]`). +dictionary (anything implementing `System.Collections.IDictionary`, such as `@{}`, +`[ordered]@{}` or a generic `Dictionary[,]`). It does not compare the contents of the dictionary. Use the optional parameters to assert on the shape of the dictionary: - `-Count` checks the number of entries. -- `-Ordered` checks that the value is an ordered dictionary (`[ordered]@\{\}`). +- `-Ordered` checks that the value is an ordered dictionary (`[ordered]@{}`). - `-Key` checks that the given keys are present, ignoring their values. When combined with `-Ordered`, the keys must also appear in the given relative order. @@ -90,15 +90,41 @@ The value to test. It is expected to be a hashtable or dictionary. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Because + +The reason why the input should be a hashtable with the expected shape. + +```yaml +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Count @@ -106,15 +132,20 @@ Accept wildcard characters: False Checks that the dictionary has the expected number of entries. ```yaml -Type: Int32 -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Int32 +DefaultValue: 0 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Key @@ -126,57 +157,56 @@ When `-Ordered` is also specified, the keys must appear in the dictionary in the same relative order as they are listed here. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Ordered Checks that the dictionary is an ordered dictionary (`System.Collections.Specialized.OrderedDictionary`), -as produced by `[ordered]@\{\}`. +as produced by `[ordered]@{}`. A plain `[hashtable]` is unordered and fails this check. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Because - -The reason why the input should be a hashtable with the expected shape. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -193,10 +223,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeHashtable](https://pester.dev/docs/commands/Should-BeHashtable) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeHashtable](https://pester.dev/docs/commands/Should-BeHashtable) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeLessThan.mdx b/docs/commands/Should-BeLessThan.mdx index 798945a..d508a1a 100644 --- a/docs/commands/Should-BeLessThan.mdx +++ b/docs/commands/Should-BeLessThan.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if the actual value is less ## SYNTAX ```powershell -Should-BeLessThan [[-Actual] ] [-Expected] [-Because ] [] +Should-BeLessThan [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -48,55 +48,75 @@ These assertions will pass, because the actual value is less than the expected v The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +129,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeLessThan](https://pester.dev/docs/commands/Should-BeLessThan) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeLessThan](https://pester.dev/docs/commands/Should-BeLessThan) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeLessThanOrEqual.mdx b/docs/commands/Should-BeLessThanOrEqual.mdx index 33414ae..db9b456 100644 --- a/docs/commands/Should-BeLessThanOrEqual.mdx +++ b/docs/commands/Should-BeLessThanOrEqual.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if the actual value is less ## SYNTAX ```powershell -Should-BeLessThanOrEqual [[-Actual] ] [-Expected] [-Because ] [] +Should-BeLessThanOrEqual [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -56,55 +56,75 @@ This assertion will fail, because the actual value is not less than or equal to The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -119,10 +139,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeLessThanOrEqual](https://pester.dev/docs/commands/Should-BeLessThanOrEqual) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeLessThanOrEqual](https://pester.dev/docs/commands/Should-BeLessThanOrEqual) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeLikeString.mdx b/docs/commands/Should-BeLikeString.mdx index 2f1bb71..02c3239 100644 --- a/docs/commands/Should-BeLikeString.mdx +++ b/docs/commands/Should-BeLikeString.mdx @@ -23,8 +23,7 @@ Asserts that the actual value is like the expected value. ## SYNTAX ```powershell -Should-BeLikeString [[-Actual] ] [-Expected] [-CaseSensitive] [-Because ] - [] +Should-BeLikeString [-Expected] [[-Actual] ] [-CaseSensitive] [-Because ] ``` ## DESCRIPTION @@ -57,31 +56,41 @@ This assertion will fail, because the actual value is not like the expected valu The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the actual value should be like the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CaseSensitive @@ -89,39 +98,54 @@ Accept wildcard characters: False Indicates that the comparison should be case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should be like the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -136,10 +160,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeLikeString](https://pester.dev/docs/commands/Should-BeLikeString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeLikeString](https://pester.dev/docs/commands/Should-BeLikeString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeNull.mdx b/docs/commands/Should-BeNull.mdx index 9f853ac..b78c796 100644 --- a/docs/commands/Should-BeNull.mdx +++ b/docs/commands/Should-BeNull.mdx @@ -23,7 +23,7 @@ Asserts that the input is `$null`. ## SYNTAX ```powershell -Should-BeNull [[-Actual] ] [-Because ] [] +Should-BeNull [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -48,15 +48,20 @@ This assertion will pass, because the actual value is `$null`. The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -64,23 +69,33 @@ Accept wildcard characters: False The reason why the input should be `$null`. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -93,10 +108,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeNull](https://pester.dev/docs/commands/Should-BeNull) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeNull](https://pester.dev/docs/commands/Should-BeNull) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeSame.mdx b/docs/commands/Should-BeSame.mdx index d341247..ef64674 100644 --- a/docs/commands/Should-BeSame.mdx +++ b/docs/commands/Should-BeSame.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if they are the same instanc ## SYNTAX ```powershell -Should-BeSame [[-Actual] ] [-Expected] [-Because ] [] +Should-BeSame [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -59,55 +59,75 @@ This assertion will fail, because the actual value is not the same instance as t The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -122,10 +142,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeSame](https://pester.dev/docs/commands/Should-BeSame) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeSame](https://pester.dev/docs/commands/Should-BeSame) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeSlowerThan.mdx b/docs/commands/Should-BeSlowerThan.mdx index d780903..2991baa 100644 --- a/docs/commands/Should-BeSlowerThan.mdx +++ b/docs/commands/Should-BeSlowerThan.mdx @@ -23,7 +23,7 @@ Asserts that the provided [timespan] is slower than the expected [timespan]. ## SYNTAX ```powershell -Should-BeSlowerThan [[-Actual] ] [[-Expected] ] [-Because ] [] +Should-BeSlowerThan [[-Expected] ] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -64,55 +64,75 @@ This assertion will fail, because the actual value is not slower than the expect The actual [timespan] or [scriptblock] value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected [timespan] or fluent time value. +The reason why the actual value should be slower than the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should be slower than the expected value. +The expected [timespan] or fluent time value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -127,10 +147,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeSlowerThan](https://pester.dev/docs/commands/Should-BeSlowerThan) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeSlowerThan](https://pester.dev/docs/commands/Should-BeSlowerThan) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeString.mdx b/docs/commands/Should-BeString.mdx index c12baf4..b26c485 100644 --- a/docs/commands/Should-BeString.mdx +++ b/docs/commands/Should-BeString.mdx @@ -23,8 +23,8 @@ Asserts that the actual value is equal to the expected value. ## SYNTAX ```powershell -Should-BeString [[-Actual] ] [-Expected] [-Because ] [-CaseSensitive] - [-IgnoreWhitespace] [-TrimWhitespace] [] +Should-BeString [-Expected] [[-Actual] ] [-Because ] [-CaseSensitive] + [-IgnoreWhitespace] [-TrimWhitespace] ``` ## DESCRIPTION @@ -57,63 +57,83 @@ This assertion will fail, because the actual value is not equal to the expected The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the actual value should be equal to the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -CaseSensitive -The reason why the actual value should be equal to the expected value. +Indicates that the comparison should be case-sensitive. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -CaseSensitive +### -Expected -Indicates that the comparison should be case-sensitive. +The expected value. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -IgnoreWhitespace @@ -121,15 +141,20 @@ Accept wildcard characters: False Indicates that the comparison should ignore whitespace. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -TrimWhitespace @@ -137,23 +162,33 @@ Accept wildcard characters: False Trims whitespace at the start and end of the string. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -168,10 +203,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeString](https://pester.dev/docs/commands/Should-BeString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeString](https://pester.dev/docs/commands/Should-BeString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeTrue.mdx b/docs/commands/Should-BeTrue.mdx index 3306d80..f6c3ff1 100644 --- a/docs/commands/Should-BeTrue.mdx +++ b/docs/commands/Should-BeTrue.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares the actual value to a boolean $true. -It does not convert input values to boolean, and will fail for any value is not $true. +Compares the actual value to a boolean $true. It does not convert input values to boolean, and will fail for any value is not $true. ## SYNTAX ```powershell -Should-BeTrue [[-Actual] ] [[-Because] ] [] +Should-BeTrue [[-Actual] ] [[-Because] ] ``` ## DESCRIPTION @@ -62,15 +61,20 @@ All of these assertions will fail, because the actual value is not $true. The actual value to compare to $true. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -78,23 +82,33 @@ Accept wildcard characters: False The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -109,10 +123,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeTrue](https://pester.dev/docs/commands/Should-BeTrue) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeTrue](https://pester.dev/docs/commands/Should-BeTrue) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-BeTruthy.mdx b/docs/commands/Should-BeTruthy.mdx index b959914..b9ce2c4 100644 --- a/docs/commands/Should-BeTruthy.mdx +++ b/docs/commands/Should-BeTruthy.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Compares the actual value to a boolean $true. -It converts input values to boolean, and will fail for any value is not $true, or truthy. +Compares the actual value to a boolean $true. It converts input values to boolean, and will fail for any value is not $true, or truthy. ## SYNTAX ```powershell -Should-BeTruthy [[-Actual] ] [[-Because] ] [] +Should-BeTruthy [[-Actual] ] [[-Because] ] ``` ## DESCRIPTION @@ -63,15 +62,20 @@ All of these assertions will fail, because the actual value is not $true or trut The actual value to compare to $true. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -79,23 +83,33 @@ Accept wildcard characters: False The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -110,10 +124,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-BeTruthy](https://pester.dev/docs/commands/Should-BeTruthy) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-BeTruthy](https://pester.dev/docs/commands/Should-BeTruthy) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-ContainCollection.mdx b/docs/commands/Should-ContainCollection.mdx index 899d7e4..b621d87 100644 --- a/docs/commands/Should-ContainCollection.mdx +++ b/docs/commands/Should-ContainCollection.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Checks that the expected collection is present in the actual collection as an ordered subsequence. -It does not compare the types of the input collections. +Checks that the expected collection is present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. ## SYNTAX ```powershell -Should-ContainCollection [[-Actual] ] [-Expected] [-Because ] [] +Should-ContainCollection [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -66,56 +65,76 @@ These assertions fail, because an expected item is missing (`@(3, 4)`), the item The collection to search in. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -One or more items to look for as an ordered subsequence. -A single value is treated as a one-item collection. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +One or more items to look for as an ordered subsequence. +A single value is treated as a one-item collection. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -128,10 +147,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-ContainCollection](https://pester.dev/docs/commands/Should-ContainCollection) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-ContainCollection](https://pester.dev/docs/commands/Should-ContainCollection) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-HaveParameter.mdx b/docs/commands/Should-HaveParameter.mdx index 3a3c582..3508010 100644 --- a/docs/commands/Should-HaveParameter.mdx +++ b/docs/commands/Should-HaveParameter.mdx @@ -23,9 +23,9 @@ Asserts that a command has the expected parameter. ## SYNTAX ```powershell -Should-HaveParameter [[-ParameterName] ] [[-Type] ] [[-DefaultValue] ] [-Mandatory] - [[-InParameterSet] ] [-HasArgumentCompleter] [[-Alias] ] [[-Actual] ] - [[-Because] ] [] +Should-HaveParameter [[-ParameterName] ] [[-Type] ] [[-DefaultValue] ] + [[-InParameterSet] ] [[-Alias] ] [[-Actual] ] [[-Because] ] + [-Mandatory] [-HasArgumentCompleter] ``` ## DESCRIPTION @@ -84,40 +84,69 @@ This assertion passes, because the `-Index` parameter (from the `Get-Cat` functi ## PARAMETERS -### -ParameterName +### -Actual -The name of the parameter to check. +The actual command to check. E.g. -Uri +Get-Command "Invoke-WebRequest" ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 5 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Type +### -Alias -The type of the parameter to check. -E.g. -[string] +The alias of the parameter to check. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String[] +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 4 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -Because + +The reason why the input should be the expected value. + +```yaml +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 6 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -DefaultValue @@ -127,31 +156,41 @@ E.g. "https://example.com" ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Mandatory +### -HasArgumentCompleter -Whether the parameter is mandatory or not. +Whether the parameter has an argument completer or not. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -InParameterSet @@ -159,89 +198,100 @@ Accept wildcard characters: False The parameter set that the parameter belongs to. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 4 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -HasArgumentCompleter - -Whether the parameter has an argument completer or not. - -```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Alias +### -Mandatory -The alias of the parameter to check. +Whether the parameter is mandatory or not. ```yaml -Type: String[] -Parameter Sets: (All) -Aliases: - -Required: False -Position: 5 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Actual +### -ParameterName -The actual command to check. +The name of the parameter to check. E.g. -Get-Command "Invoke-WebRequest" +Uri ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 6 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Type -The reason why the input should be the expected value. +The type of the parameter to check. +E.g. +[string] ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 7 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -259,10 +309,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-HaveParameter](https://pester.dev/docs/commands/Should-HaveParameter) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-HaveParameter](https://pester.dev/docs/commands/Should-HaveParameter) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-HaveType.mdx b/docs/commands/Should-HaveType.mdx index 45b584e..32c0eb6 100644 --- a/docs/commands/Should-HaveType.mdx +++ b/docs/commands/Should-HaveType.mdx @@ -23,7 +23,7 @@ Asserts that the input is of the expected type. ## SYNTAX ```powershell -Should-HaveType [[-Actual] ] [-Expected] [-Because ] [] +Should-HaveType [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -49,55 +49,75 @@ These assertions will pass, because the actual value is of the expected type. The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected type. +The reason why the input should be the expected type. ```yaml -Type: Type -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected type. +The expected type. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Type +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -110,10 +130,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-HaveType](https://pester.dev/docs/commands/Should-HaveType) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-HaveType](https://pester.dev/docs/commands/Should-HaveType) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-Invoke.mdx b/docs/commands/Should-Invoke.mdx index 3432828..4b301ea 100644 --- a/docs/commands/Should-Invoke.mdx +++ b/docs/commands/Should-Invoke.mdx @@ -26,28 +26,28 @@ and throws an exception if it has not. ### Default (Default) ```powershell -Should-Invoke [-CommandName] [[-Times] ] [-ParameterFilter ] - [-ExclusiveFilter ] [-ModuleName ] [-Scope ] [-Exactly] [-Because ] - [] +Should-Invoke [-CommandName] [[-Times] ] [-ParameterFilter ] + [-ExclusiveFilter ] [-ModuleName ] [-Scope ] [-Exactly] + [-Because ] ``` ### ExclusiveFilter ```powershell -Should-Invoke -ExclusiveFilter [] +Should-Invoke -ExclusiveFilter ``` ### Verifiable ```powershell -Should-Invoke [-Because ] [-Verifiable] [] +Should-Invoke [-Because ] [-Verifiable] ``` ## DESCRIPTION This command verifies that a mocked command has been called a certain number -of times. -If the call history of the mocked command does not match the parameters +of times. + If the call history of the mocked command does not match the parameters passed to Should-Invoke, Should-Invoke will throw an exception. ## EXAMPLES @@ -150,91 +150,112 @@ It is a shorthand for pairing a `Should-Invoke` and a `Should-NotInvoke`. ## PARAMETERS -### -CommandName +### -Because -The mocked command whose call history should be checked. +The reason why the mock should be called. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Verifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Times +### -CommandName -The number of times that the mock must be called to avoid an exception -from throwing. +The mocked command whose call history should be checked. ```yaml -Type: Int32 -Parameter Sets: Default -Aliases: - -Required: False -Position: 2 -Default value: 1 -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ParameterFilter +### -Exactly -An optional filter to qualify which calls should be counted. -Only those -calls to the mock whose parameters cause this filter to return true -will be counted. +If this switch is present, the number specified in Times must match +exactly the number of times the mock has been called. +Otherwise it +must match "at least" the number of times specified. + If the value +passed to the Times parameter is zero, the Exactly switch is implied. ```yaml -Type: ScriptBlock -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: { $True } -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExclusiveFilter Like ParameterFilter, except when you use ExclusiveFilter, and there were any calls to the mocked command which do not match the filter, -an exception will be thrown. -This is a convenient way to avoid needing +an exception will be thrown. + This is a convenient way to avoid needing to have two calls to Should-Invoke like this: Should-Invoke SomeCommand -Times 1 -ParameterFilter \{ $something -eq $true \} Should-Invoke SomeCommand -Times 0 -ParameterFilter \{ $something -ne $true \} ```yaml -Type: ScriptBlock -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - -```yaml -Type: ScriptBlock -Parameter Sets: ExclusiveFilter -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: ExclusiveFilter + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ModuleName @@ -244,15 +265,44 @@ This is optional, and must match the ModuleName that was used when setting up the Mock. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -ParameterFilter + +An optional filter to qualify which calls should be counted. +Only those +calls to the mock whose parameters cause this filter to return true +will be counted. + +```yaml +Type: System.Management.Automation.ScriptBlock +DefaultValue: '{ $True }' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Scope @@ -269,52 +319,42 @@ Context, the command will identify all calls to the mocked command in the current Describe / Context block, as well as all child scopes of that block. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Exactly - -If this switch is present, the number specified in Times must match -exactly the number of times the mock has been called. -Otherwise it -must match "at least" the number of times specified. -If the value -passed to the Times parameter is zero, the Exactly switch is implied. - -```yaml -Type: SwitchParameter -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: 0 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Times -The reason why the mock should be called. +The number of times that the mock must be called to avoid an exception +from throwing. ```yaml -Type: String -Parameter Sets: Default, Verifiable -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Int32 +DefaultValue: 1 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Verifiable @@ -322,20 +362,28 @@ Accept wildcard characters: False Makes sure that all verifiable mocks were called. ```yaml -Type: SwitchParameter -Parameter Sets: Verifiable -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Verifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -344,10 +392,10 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## NOTES The parameter filter passed to Should-Invoke does not necessarily have to match the parameter filter -(if any) which was used to create the Mock. -Should-Invoke will find any entry in the command history -which matches its parameter filter, regardless of how the Mock was created. -However, if any calls to the +(if any) which was used to create the Mock. + Should-Invoke will find any entry in the command history +which matches its parameter filter, regardless of how the Mock was created. + However, if any calls to the mocked command are made which did not match any mock's parameter filter (resulting in the original command being executed instead of a mock), these calls to the original command are not tracked in the call history. In other words, Should-Invoke can only be used to check for calls to the mocked implementation, not @@ -361,10 +409,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-Invoke](https://pester.dev/docs/commands/Should-Invoke) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-Invoke](https://pester.dev/docs/commands/Should-Invoke) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-MatchString.mdx b/docs/commands/Should-MatchString.mdx index b8ca0a0..b39f5b6 100644 --- a/docs/commands/Should-MatchString.mdx +++ b/docs/commands/Should-MatchString.mdx @@ -23,8 +23,7 @@ Tests whether a string matches a regular expression pattern. ## SYNTAX ```powershell -Should-MatchString [[-Actual] ] [-Expected] [-CaseSensitive] [-Because ] - [] +Should-MatchString [-Expected] [[-Actual] ] [-CaseSensitive] [-Because ] ``` ## DESCRIPTION @@ -66,31 +65,41 @@ This assertion fails, because with `-CaseSensitive` the lowercase `pester` in th The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected regular expression pattern. +The reason why the actual value should match the regular expression pattern. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CaseSensitive @@ -98,39 +107,54 @@ Accept wildcard characters: False Indicates that the comparison should be case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should match the regular expression pattern. +The expected regular expression pattern. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -143,10 +167,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-MatchString](https://pester.dev/docs/commands/Should-MatchString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-MatchString](https://pester.dev/docs/commands/Should-MatchString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBe.mdx b/docs/commands/Should-NotBe.mdx index f4d627b..c35b1f9 100644 --- a/docs/commands/Should-NotBe.mdx +++ b/docs/commands/Should-NotBe.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if they are not equal. ## SYNTAX ```powershell -Should-NotBe [[-Actual] ] [-Expected] [-Because ] [] +Should-NotBe [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -49,55 +49,75 @@ These assertions will pass, because the actual value is not equal to the expecte The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should not be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should not be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -110,10 +130,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBe](https://pester.dev/docs/commands/Should-NotBe) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBe](https://pester.dev/docs/commands/Should-NotBe) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeEmptyString.mdx b/docs/commands/Should-NotBeEmptyString.mdx index e24891e..07754da 100644 --- a/docs/commands/Should-NotBeEmptyString.mdx +++ b/docs/commands/Should-NotBeEmptyString.mdx @@ -23,7 +23,7 @@ Ensures that the input is a string, and that the input is not $null or empty str ## SYNTAX ```powershell -Should-NotBeEmptyString [[-Actual] ] [-Because ] [] +Should-NotBeEmptyString [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -69,15 +69,20 @@ All the tests above will fail, the input is not a string. The actual value that will be compared. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -85,23 +90,33 @@ Accept wildcard characters: False The reason why the input should be a string that is not $null or empty. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -114,10 +129,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeEmptyString](https://pester.dev/docs/commands/Should-NotBeEmptyString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeEmptyString](https://pester.dev/docs/commands/Should-NotBeEmptyString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeLikeString.mdx b/docs/commands/Should-NotBeLikeString.mdx index 4a1b976..30d27ed 100644 --- a/docs/commands/Should-NotBeLikeString.mdx +++ b/docs/commands/Should-NotBeLikeString.mdx @@ -23,8 +23,8 @@ Asserts that the actual value is not like the expected value. ## SYNTAX ```powershell -Should-NotBeLikeString [[-Actual] ] [-Expected] [-CaseSensitive] [-Because ] - [] +Should-NotBeLikeString [-Expected] [[-Actual] ] [-CaseSensitive] + [-Because ] ``` ## DESCRIPTION @@ -57,31 +57,41 @@ This assertion will fail, because the actual value is like the expected value. The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the actual value should not be like the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CaseSensitive @@ -89,39 +99,54 @@ Accept wildcard characters: False Indicates that the comparison should be case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should not be like the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -136,10 +161,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeLikeString](https://pester.dev/docs/commands/Should-NotBeLikeString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeLikeString](https://pester.dev/docs/commands/Should-NotBeLikeString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeNull.mdx b/docs/commands/Should-NotBeNull.mdx index 5d9b4a7..6d7ab24 100644 --- a/docs/commands/Should-NotBeNull.mdx +++ b/docs/commands/Should-NotBeNull.mdx @@ -23,7 +23,7 @@ Asserts that the input is not `$null`. ## SYNTAX ```powershell -Should-NotBeNull [[-Actual] ] [-Because ] [] +Should-NotBeNull [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -49,15 +49,20 @@ These assertions will pass, because the actual value is not `$null. The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -65,23 +70,33 @@ Accept wildcard characters: False The reason why the input should not be `$null`. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -94,10 +109,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeNull](https://pester.dev/docs/commands/Should-NotBeNull) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeNull](https://pester.dev/docs/commands/Should-NotBeNull) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeSame.mdx b/docs/commands/Should-NotBeSame.mdx index e2ae196..fc09cb6 100644 --- a/docs/commands/Should-NotBeSame.mdx +++ b/docs/commands/Should-NotBeSame.mdx @@ -23,7 +23,7 @@ Compares the expected value to actual value, to see if the actual value is not t ## SYNTAX ```powershell -Should-NotBeSame [[-Actual] ] [-Expected] [-Because ] [] +Should-NotBeSame [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -58,55 +58,75 @@ This assertion will fail, because the actual value is the same instance as the e The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the input should not be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should not be the expected value. +The expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -121,10 +141,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeSame](https://pester.dev/docs/commands/Should-NotBeSame) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeSame](https://pester.dev/docs/commands/Should-NotBeSame) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeString.mdx b/docs/commands/Should-NotBeString.mdx index 925f0a1..2fd4a7a 100644 --- a/docs/commands/Should-NotBeString.mdx +++ b/docs/commands/Should-NotBeString.mdx @@ -23,8 +23,8 @@ Asserts that the actual value is not equal to the expected value. ## SYNTAX ```powershell -Should-NotBeString [[-Actual] ] [[-Expected] ] [-Because ] [-CaseSensitive] - [-IgnoreWhitespace] [] +Should-NotBeString [[-Expected] ] [[-Actual] ] [-Because ] [-CaseSensitive] + [-IgnoreWhitespace] ``` ## DESCRIPTION @@ -57,63 +57,83 @@ This assertion will fail, because the actual value is equal to the expected valu The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected value. +The reason why the actual value should not be equal to the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -CaseSensitive -The reason why the actual value should not be equal to the expected value. +Indicates that the comparison should be case-sensitive. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -CaseSensitive +### -Expected -Indicates that the comparison should be case-sensitive. +The expected value. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -IgnoreWhitespace @@ -121,23 +141,33 @@ Accept wildcard characters: False Indicates that the comparison should ignore whitespace. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -152,10 +182,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeString](https://pester.dev/docs/commands/Should-NotBeString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeString](https://pester.dev/docs/commands/Should-NotBeString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotBeWhiteSpaceString.mdx b/docs/commands/Should-NotBeWhiteSpaceString.mdx index c00369f..ac8a008 100644 --- a/docs/commands/Should-NotBeWhiteSpaceString.mdx +++ b/docs/commands/Should-NotBeWhiteSpaceString.mdx @@ -23,7 +23,7 @@ Ensures that the input is a string, and that the input is not $null, empty, or w ## SYNTAX ```powershell -Should-NotBeWhiteSpaceString [[-Actual] ] [-Because ] [] +Should-NotBeWhiteSpaceString [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -70,15 +70,20 @@ All the tests above will fail, the input is not a string. The actual value that will be compared. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -86,23 +91,33 @@ Accept wildcard characters: False The reason why the input should be a string that is not $null, empty, or whitespace only string. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -115,10 +130,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotBeWhiteSpaceString](https://pester.dev/docs/commands/Should-NotBeWhiteSpaceString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotBeWhiteSpaceString](https://pester.dev/docs/commands/Should-NotBeWhiteSpaceString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotContainCollection.mdx b/docs/commands/Should-NotContainCollection.mdx index e8257bf..629b9c4 100644 --- a/docs/commands/Should-NotContainCollection.mdx +++ b/docs/commands/Should-NotContainCollection.mdx @@ -18,13 +18,12 @@ Contributions are welcome in [Pester-repo](https://github.com/pester/pester). ## SYNOPSIS -Checks that the expected collection is not present in the actual collection as an ordered subsequence. -It does not compare the types of the input collections. +Checks that the expected collection is not present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. ## SYNTAX ```powershell -Should-NotContainCollection [[-Actual] ] [-Expected] [-Because ] [] +Should-NotContainCollection [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -64,56 +63,76 @@ Gaps between them, as in `@(1, 3)`, are allowed. The collection to search in. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -One or more items to look for as an ordered subsequence. -A single value is treated as a one-item collection. +The reason why the input should be the expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should be the expected value. +One or more items to look for as an ordered subsequence. +A single value is treated as a one-item collection. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -126,10 +145,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotContainCollection](https://pester.dev/docs/commands/Should-NotContainCollection) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotContainCollection](https://pester.dev/docs/commands/Should-NotContainCollection) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotHaveParameter.mdx b/docs/commands/Should-NotHaveParameter.mdx index 44f3d8b..e14bf85 100644 --- a/docs/commands/Should-NotHaveParameter.mdx +++ b/docs/commands/Should-NotHaveParameter.mdx @@ -23,8 +23,7 @@ Asserts that a command has does not have the parameter. ## SYNTAX ```powershell -Should-NotHaveParameter [[-ParameterName] ] [[-Actual] ] [[-Because] ] - [] +Should-NotHaveParameter [[-ParameterName] ] [[-Actual] ] [[-Because] ] ``` ## DESCRIPTION @@ -57,24 +56,6 @@ This is useful for guarding against accidentally adding parameters you want to k ## PARAMETERS -### -ParameterName - -The name of the parameter to check. -E.g. -Uri - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False -``` - ### -Actual The actual command to check. @@ -82,15 +63,20 @@ E.g. Get-Command "Invoke-WebRequest" ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because @@ -98,23 +84,56 @@ Accept wildcard characters: False The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' +``` + +### -ParameterName + +The name of the parameter to check. +E.g. +Uri + +```yaml +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -127,10 +146,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotHaveParameter](https://pester.dev/docs/commands/Should-NotHaveParameter) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotHaveParameter](https://pester.dev/docs/commands/Should-NotHaveParameter) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotHaveType.mdx b/docs/commands/Should-NotHaveType.mdx index 1fa4c82..5a2dc35 100644 --- a/docs/commands/Should-NotHaveType.mdx +++ b/docs/commands/Should-NotHaveType.mdx @@ -23,7 +23,7 @@ Asserts that the input is not of the expected type. ## SYNTAX ```powershell -Should-NotHaveType [[-Actual] ] [-Expected] [-Because ] [] +Should-NotHaveType [-Expected] [[-Actual] ] [-Because ] ``` ## DESCRIPTION @@ -49,55 +49,75 @@ These assertions will pass, because the actual value is not of the expected type The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected type. +The reason why the input should not be the expected type. ```yaml -Type: Type -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the input should not be the expected type. +The expected type. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Type +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -112,10 +132,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotHaveType](https://pester.dev/docs/commands/Should-NotHaveType) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotHaveType](https://pester.dev/docs/commands/Should-NotHaveType) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotInvoke.mdx b/docs/commands/Should-NotInvoke.mdx index 815eff5..61112a4 100644 --- a/docs/commands/Should-NotInvoke.mdx +++ b/docs/commands/Should-NotInvoke.mdx @@ -25,28 +25,28 @@ Checks that mocked command was not called and throws exception if it was. ### Default (Default) ```powershell -Should-NotInvoke [-CommandName] [[-Times] ] [-ParameterFilter ] - [-ExclusiveFilter ] [-ModuleName ] [-Scope ] [-Exactly] [-Because ] - [] +Should-NotInvoke [-CommandName] [[-Times] ] [-ParameterFilter ] + [-ExclusiveFilter ] [-ModuleName ] [-Scope ] [-Exactly] + [-Because ] ``` ### ExclusiveFilter ```powershell -Should-NotInvoke -ExclusiveFilter [] +Should-NotInvoke -ExclusiveFilter ``` ### Verifiable ```powershell -Should-NotInvoke [-Because ] [-Verifiable] [] +Should-NotInvoke [-Because ] [-Verifiable] ``` ## DESCRIPTION This command verifies that a mocked command has not been called a certain number -of times. -If the call history of the mocked command does not match the parameters +of times. + If the call history of the mocked command does not match the parameters passed to Should-NotInvoke, Should-NotInvoke will throw an exception. ## EXAMPLES @@ -103,109 +103,159 @@ Describe 'Remove-TempFile' { ## PARAMETERS -### -CommandName +### -Because -The mocked command whose call history should be checked. +The reason why the mock should be called. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Verifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Times +### -CommandName -The number of times that the mock must be called to avoid an exception -from throwing. +The mocked command whose call history should be checked. ```yaml -Type: Int32 -Parameter Sets: Default -Aliases: - -Required: False -Position: 2 -Default value: 1 -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ParameterFilter +### -Exactly -An optional filter to qualify which calls should be counted. -Only those -calls to the mock whose parameters cause this filter to return true -will be counted. +If this switch is present, the number specified in Times must match +exactly the number of times the mock has been called. +Otherwise it +must match "at least" the number of times specified. + If the value +passed to the Times parameter is zero, the Exactly switch is implied. ```yaml -Type: ScriptBlock -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: { $True } -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExclusiveFilter Like ParameterFilter, except when you use ExclusiveFilter, and there were any calls to the mocked command which do not match the filter, -an exception will be thrown. -This is a convenient way to avoid needing +an exception will be thrown. + This is a convenient way to avoid needing to have two calls to Should-NotInvoke like this: Should-NotInvoke SomeCommand -Times 1 -ParameterFilter \{ $something -eq $true \} Should-NotInvoke SomeCommand -Times 0 -ParameterFilter \{ $something -ne $true \} ```yaml -Type: ScriptBlock -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: ExclusiveFilter + Position: Named + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` +### -ModuleName + +The module where the mock being checked was injected. + This is optional, +and must match the ModuleName that was used when setting up the Mock. + ```yaml -Type: ScriptBlock -Parameter Sets: ExclusiveFilter -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ModuleName +### -ParameterFilter -The module where the mock being checked was injected. -This is optional, -and must match the ModuleName that was used when setting up the Mock. +An optional filter to qualify which calls should be counted. +Only those +calls to the mock whose parameters cause this filter to return true +will be counted. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '{ $True }' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Scope @@ -222,52 +272,42 @@ Context, the command will identify all calls to the mocked command in the current Describe / Context block, as well as all child scopes of that block. ```yaml -Type: String -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: 0 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Exactly - -If this switch is present, the number specified in Times must match -exactly the number of times the mock has been called. -Otherwise it -must match "at least" the number of times specified. -If the value -passed to the Times parameter is zero, the Exactly switch is implied. - -```yaml -Type: SwitchParameter -Parameter Sets: Default -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -Because +### -Times -The reason why the mock should be called. +The number of times that the mock must be called to avoid an exception +from throwing. ```yaml -Type: String -Parameter Sets: Default, Verifiable -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Int32 +DefaultValue: 1 +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Default + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Verifiable @@ -275,20 +315,28 @@ Accept wildcard characters: False Makes sure that all verifiable mocks were called. ```yaml -Type: SwitchParameter -Parameter Sets: Verifiable -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Verifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -297,10 +345,10 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## NOTES The parameter filter passed to Should-NotInvoke does not necessarily have to match the parameter filter -(if any) which was used to create the Mock. -Should-NotInvoke will find any entry in the command history -which matches its parameter filter, regardless of how the Mock was created. -However, if any calls to the +(if any) which was used to create the Mock. + Should-NotInvoke will find any entry in the command history +which matches its parameter filter, regardless of how the Mock was created. + However, if any calls to the mocked command are made which did not match any mock's parameter filter (resulting in the original command being executed instead of a mock), these calls to the original command are not tracked in the call history. In other words, Should-NotInvoke can only be used to check for calls to the mocked implementation, not @@ -314,10 +362,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotInvoke](https://pester.dev/docs/commands/Should-NotInvoke) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotInvoke](https://pester.dev/docs/commands/Should-NotInvoke) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-NotMatchString.mdx b/docs/commands/Should-NotMatchString.mdx index 179ea94..5e79fd9 100644 --- a/docs/commands/Should-NotMatchString.mdx +++ b/docs/commands/Should-NotMatchString.mdx @@ -23,8 +23,7 @@ Tests whether a string does not match a regular expression pattern. ## SYNTAX ```powershell -Should-NotMatchString [[-Actual] ] [-Expected] [-CaseSensitive] [-Because ] - [] +Should-NotMatchString [-Expected] [[-Actual] ] [-CaseSensitive] [-Because ] ``` ## DESCRIPTION @@ -67,31 +66,41 @@ This assertion fails, because the actual value case-sensitively contains `failed The actual value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Expected +### -Because -The expected regular expression pattern. +The reason why the actual value should not match the regular expression pattern. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: True -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CaseSensitive @@ -99,39 +108,54 @@ Accept wildcard characters: False Indicates that the comparison should be case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -Expected -The reason why the actual value should not match the regular expression pattern. +The expected regular expression pattern. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: true + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES @@ -144,10 +168,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-NotMatchString](https://pester.dev/docs/commands/Should-NotMatchString) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-NotMatchString](https://pester.dev/docs/commands/Should-NotMatchString) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should-Throw.mdx b/docs/commands/Should-Throw.mdx index d38f28c..dfd5c9b 100644 --- a/docs/commands/Should-Throw.mdx +++ b/docs/commands/Should-Throw.mdx @@ -23,8 +23,9 @@ Asserts that a script block throws an exception. ## SYNTAX ```powershell -Should-Throw -ScriptBlock [[-ExceptionMessage] ] [[-FullyQualifiedErrorId] ] - [[-ExceptionType] ] [[-Because] ] [-AllowNonTerminatingError] [] +Should-Throw [[-ExceptionMessage] ] [[-FullyQualifiedErrorId] ] + [[-ExceptionType] ] [[-Because] ] -ScriptBlock + [-AllowNonTerminatingError] ``` ## DESCRIPTION @@ -59,54 +60,68 @@ The error record is returned from the assertion and can be used in further asser ## PARAMETERS -### -ScriptBlock +### -AllowNonTerminatingError -The script block that should throw an exception. +If set, the assertion will pass if a non-terminating error is thrown. ```yaml -Type: ScriptBlock -Parameter Sets: (All) -Aliases: - -Required: True -Position: Named -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: False +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -ExceptionMessage +### -Because -The message that the exception should contain. -`-like` wildcards are supported. +The reason why the input should be the expected value. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -FullyQualifiedErrorId +### -ExceptionMessage -The FullyQualifiedErrorId that the exception should contain. +The message that the exception should contain. `-like` wildcards are supported. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 2 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExceptionType @@ -114,55 +129,76 @@ Accept wildcard characters: False The type of exception that should be thrown. ```yaml -Type: Type -Parameter Sets: (All) -Aliases: - -Required: False -Position: 3 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Type +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -Because +### -FullyQualifiedErrorId -The reason why the input should be the expected value. +The FullyQualifiedErrorId that the exception should contain. +`-like` wildcards are supported. ```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: 4 -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.String +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` -### -AllowNonTerminatingError +### -ScriptBlock -If set, the assertion will pass if a non-terminating error is thrown. +The script block that should throw an exception. ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: False -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.ScriptBlock +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: Named + IsRequired: true + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Management.Automation.ScriptBlock + ## OUTPUTS ## NOTES @@ -175,10 +211,9 @@ See https://pester.dev/docs/assertions/soft-assertions for more about soft asser ## RELATED LINKS -[https://pester.dev/docs/commands/Should-Throw](https://pester.dev/docs/commands/Should-Throw) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should-Throw](https://pester.dev/docs/commands/Should-Throw) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/docs/commands/Should.mdx b/docs/commands/Should.mdx index e004e43..f3f0de2 100644 --- a/docs/commands/Should.mdx +++ b/docs/commands/Should.mdx @@ -22,189 +22,8 @@ Should is a keyword that is used to define an assertion inside an It block. ## SYNTAX -### Be - -```powershell -Should [[-ActualValue] ] [-Be] [-Not] [-ExpectedValue ] - [-Because ] [] -``` - -### BeExactly - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeExactly] [] -``` - -### BeGreaterThan - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeGreaterThan] [] -``` - -### BeLessOrEqual - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeLessOrEqual] [] -``` - -### BeIn - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeIn] [] -``` - -### BeLessThan - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeLessThan] [] -``` - -### BeGreaterOrEqual - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeGreaterOrEqual] [] -``` - -### BeLike - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeLike] [] -``` - -### BeLikeExactly - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-BeLikeExactly] [] -``` - -### BeNullOrEmpty - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-BeNullOrEmpty] [] -``` - -### BeOfType - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-BeOfType] - [-ExpectedType ] [] -``` - -### BeTrue - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-BeTrue] - [] -``` - -### BeFalse - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-BeFalse] - [] -``` - -### Contain - -```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-Contain] [] -``` - -### Exist - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-Exist] - [-LiteralPath] [] -``` - -### FileContentMatch - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-FileContentMatch] [-ExpectedContent ] [] -``` - -### FileContentMatchExactly - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-ExpectedContent ] [-FileContentMatchExactly] [] -``` - -### FileContentMatchMultiline - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-ExpectedContent ] [-FileContentMatchMultiline] [] -``` - -### FileContentMatchMultilineExactly - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-ExpectedContent ] [-FileContentMatchMultilineExactly] [] -``` - -### HaveCount - ```powershell -Should [[-ActualValue] ] [-Not] [-ExpectedValue ] - [-Because ] [-HaveCount] [] -``` - -### HaveParameter - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-HaveParameter] [-ParameterName ] [-Type ] [-DefaultValue ] [-Mandatory] - [-InParameterSet ] [-HasArgumentCompleter] [-Alias ] [] -``` - -### Match - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-Match] - [-RegularExpression ] [] -``` - -### MatchExactly - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-RegularExpression ] [-MatchExactly] [] -``` - -### Throw - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-Throw] - [-ExpectedMessage ] [-ErrorId ] [-ExceptionType ] [-PassThru] [] -``` - -### InvokeVerifiable - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] - [-InvokeVerifiable] [] -``` - -### Invoke - -```powershell -Should [[-ActualValue] ] [-Not] [-Because ] [-Invoke] - [-CommandName ] [-Times ] [-ParameterFilter ] [-ExclusiveFilter ] - [-ModuleName ] [-Scope ] [-Exactly] [-CallerSessionState ] - [-CommandDisplayName ] [] +Should [[-ActualValue] ] ``` ## DESCRIPTION @@ -296,32 +115,41 @@ The actual value that was obtained in the test which should be verified against a expected value. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: 1 -Default value: None -Accept pipeline input: True (ByValue) -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: (All) + Position: 0 + IsRequired: false + ValueFromPipeline: true + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: true +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Alias -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 7 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Be @@ -329,49 +157,214 @@ Accept wildcard characters: False Compares one object with another for equality and throws if the two objects are not the same. ```yaml -Type: SwitchParameter -Parameter Sets: Be -Aliases: EQ - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- EQ +ParameterSets: +- Name: Be + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Because -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Be + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeExactly + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterThan + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessOrEqual + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeIn + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessThan + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterOrEqual + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLike + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLikeExactly + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeNullOrEmpty + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeOfType + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeTrue + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeFalse + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Contain + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Exist + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatch + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchExactly + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultiline + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultilineExactly + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: HaveCount + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: HaveParameter + Position: 8 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Match + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: MatchExactly + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Throw + Position: 4 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: InvokeVerifiable + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Invoke + Position: 8 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeExactly -Compares one object with another for equality and throws if the two objects are not the same. -This comparison is case sensitive. +Compares one object with another for equality and throws if the two objects are not the same. This comparison is case sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: BeExactly -Aliases: CEQ - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- CEQ +ParameterSets: +- Name: BeExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeFalse @@ -379,151 +372,192 @@ Accept wildcard characters: False Asserts that the value is false, or falsy. ```yaml -Type: SwitchParameter -Parameter Sets: BeFalse -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeFalse + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeGreaterOrEqual -Asserts that a number (or other comparable value) is greater than or equal to an expected value. -Uses PowerShell's -ge operator to compare the two values. +Asserts that a number (or other comparable value) is greater than or equal to an expected value. Uses PowerShell's -ge operator to compare the two values. ```yaml -Type: SwitchParameter -Parameter Sets: BeGreaterOrEqual -Aliases: GE - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- GE +ParameterSets: +- Name: BeGreaterOrEqual + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeGreaterThan -Asserts that a number (or other comparable value) is greater than an expected value. -Uses PowerShell's -gt operator to compare the two values. +Asserts that a number (or other comparable value) is greater than an expected value. Uses PowerShell's -gt operator to compare the two values. ```yaml -Type: SwitchParameter -Parameter Sets: BeGreaterThan -Aliases: GT - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- GT +ParameterSets: +- Name: BeGreaterThan + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeIn -Asserts that a collection of values contain a specific value. -Uses PowerShell's -contains operator to confirm. +Asserts that a collection of values contain a specific value. Uses PowerShell's -contains operator to confirm. ```yaml -Type: SwitchParameter -Parameter Sets: BeIn -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeIn + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeLessOrEqual -Asserts that a number (or other comparable value) is lower than, or equal to an expected value. -Uses PowerShell's -le operator to compare the two values. +Asserts that a number (or other comparable value) is lower than, or equal to an expected value. Uses PowerShell's -le operator to compare the two values. ```yaml -Type: SwitchParameter -Parameter Sets: BeLessOrEqual -Aliases: LE - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- LE +ParameterSets: +- Name: BeLessOrEqual + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeLessThan -Asserts that a number (or other comparable value) is lower than an expected value. -Uses PowerShell's -lt operator to compare the two values. +Asserts that a number (or other comparable value) is lower than an expected value. Uses PowerShell's -lt operator to compare the two values. ```yaml -Type: SwitchParameter -Parameter Sets: BeLessThan -Aliases: LT - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- LT +ParameterSets: +- Name: BeLessThan + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeLike -Asserts that the actual value matches a wildcard pattern using PowerShell's -like operator. -This comparison is not case-sensitive. +Asserts that the actual value matches a wildcard pattern using PowerShell's -like operator. This comparison is not case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: BeLike -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeLike + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeLikeExactly -Asserts that the actual value matches a wildcard pattern using PowerShell's -like operator. -This comparison is case-sensitive. +Asserts that the actual value matches a wildcard pattern using PowerShell's -like operator. This comparison is case-sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: BeLikeExactly -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeLikeExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeNullOrEmpty -Checks values for null or empty (strings). -The static [String]::IsNullOrEmpty() method is used to do the comparison. +Checks values for null or empty (strings). The static [String]::IsNullOrEmpty() method is used to do the comparison. ```yaml -Type: SwitchParameter -Parameter Sets: BeNullOrEmpty -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeNullOrEmpty + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeOfType @@ -531,15 +565,21 @@ Accept wildcard characters: False Asserts that the actual value should be an object of a specified type (or a subclass of the specified type) using PowerShell's -is operator. ```yaml -Type: SwitchParameter -Parameter Sets: BeOfType -Aliases: HaveType - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- HaveType +ParameterSets: +- Name: BeOfType + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -BeTrue @@ -547,288 +587,434 @@ Accept wildcard characters: False Asserts that the value is true, or truthy. ```yaml -Type: SwitchParameter -Parameter Sets: BeTrue -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeTrue + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CallerSessionState -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 9 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CommandDisplayName -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 10 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -CommandName -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Contain -Asserts that collection contains a specific value. -Uses PowerShell's -contains operator to confirm. +Asserts that collection contains a specific value. Uses PowerShell's -contains operator to confirm. ```yaml -Type: SwitchParameter -Parameter Sets: Contain -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Contain + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -DefaultValue -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ErrorId -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Throw -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Throw + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Exactly -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: SwitchParameter -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 7 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExceptionType -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Throw -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Throw + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExclusiveFilter -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 4 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Exist -Does not perform any comparison, but checks if the object calling Exist is present in a PS Provider. -The object must have valid path syntax. -It essentially must pass a Test-Path call. +Does not perform any comparison, but checks if the object calling Exist is present in a PS Provider. The object must have valid path syntax. It essentially must pass a Test-Path call. ```yaml -Type: SwitchParameter -Parameter Sets: Exist -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Exist + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExpectedContent -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: FileContentMatch, FileContentMatchExactly, FileContentMatchMultiline, FileContentMatchMultilineExactly -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FileContentMatch + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchExactly + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultiline + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultilineExactly + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExpectedMessage -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Throw -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Throw + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExpectedType -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: BeOfType -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: BeOfType + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ExpectedValue -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Be, BeExactly, BeGreaterThan, BeLessOrEqual, BeIn, BeLessThan, BeGreaterOrEqual, BeLike, BeLikeExactly, Contain, HaveCount -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Be + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeExactly + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterThan + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessOrEqual + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeIn + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessThan + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterOrEqual + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLike + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLikeExactly + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Contain + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: HaveCount + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FileContentMatch -Checks to see if a file contains the specified text. -This search is not case sensitive and uses regular expressions. +Checks to see if a file contains the specified text. This search is not case sensitive and uses regular expressions. ```yaml -Type: SwitchParameter -Parameter Sets: FileContentMatch -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FileContentMatch + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FileContentMatchExactly -Checks to see if a file contains the specified text. -This search is case sensitive and uses regular expressions to match the text. +Checks to see if a file contains the specified text. This search is case sensitive and uses regular expressions to match the text. ```yaml -Type: SwitchParameter -Parameter Sets: FileContentMatchExactly -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FileContentMatchExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FileContentMatchMultiline @@ -838,15 +1024,20 @@ As opposed to FileContentMatch and FileContentMatchExactly operators, FileConten When using FileContentMatchMultiline operator, '^' and '$' represent the beginning and end of the whole file, instead of the beginning and end of a line ```yaml -Type: SwitchParameter -Parameter Sets: FileContentMatchMultiline -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FileContentMatchMultiline + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -FileContentMatchMultilineExactly @@ -856,32 +1047,41 @@ As opposed to FileContentMatch and FileContentMatchExactly operators, FileConten When using FileContentMatchMultilineExactly operator, '^' and '$' represent the beginning and end of the whole file, instead of the beginning and end of a line. ```yaml -Type: SwitchParameter -Parameter Sets: FileContentMatchMultilineExactly -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: FileContentMatchMultilineExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -HasArgumentCompleter -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: SwitchParameter -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 6 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -HaveCount @@ -889,15 +1089,20 @@ Accept wildcard characters: False Asserts that a collection has the expected amount of items. ```yaml -Type: SwitchParameter -Parameter Sets: HaveCount -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveCount + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -HaveParameter @@ -905,32 +1110,41 @@ Accept wildcard characters: False Asserts that a command has the expected parameter. ```yaml -Type: SwitchParameter -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -InParameterSet -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 5 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Invoke @@ -938,117 +1152,147 @@ Accept wildcard characters: False Checks if a Mocked command has been called a certain number of times and throws an exception if it has not. ```yaml -Type: SwitchParameter -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -InvokeVerifiable -Checks if any Verifiable Mock has not been invoked. -If so, this will throw an exception. +Checks if any Verifiable Mock has not been invoked. If so, this will throw an exception. ```yaml -Type: SwitchParameter -Parameter Sets: InvokeVerifiable -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: InvokeVerifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -LiteralPath -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: SwitchParameter -Parameter Sets: Exist -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Exist + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Mandatory -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: SwitchParameter -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 4 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Match -Uses a regular expression to compare two objects. -This comparison is not case sensitive. +Uses a regular expression to compare two objects. This comparison is not case sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: Match -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Match + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -MatchExactly -Uses a regular expression to compare two objects. -This comparison is case sensitive. +Uses a regular expression to compare two objects. This comparison is case sensitive. ```yaml -Type: SwitchParameter -Parameter Sets: MatchExactly -Aliases: CMATCH - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: +- CMATCH +ParameterSets: +- Name: MatchExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ModuleName -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 5 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Not @@ -1056,169 +1300,366 @@ Accept wildcard characters: False Reverse the assertion ```yaml -Type: SwitchParameter -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Be + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterThan + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessOrEqual + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeIn + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLessThan + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeGreaterOrEqual + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLike + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeLikeExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeNullOrEmpty + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeOfType + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeTrue + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: BeFalse + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Contain + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Exist + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatch + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultiline + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: FileContentMatchMultilineExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: HaveCount + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: HaveParameter + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Match + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: MatchExactly + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Throw + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: InvokeVerifiable + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: Invoke + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ParameterFilter -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 3 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -ParameterName -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -PassThru -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: SwitchParameter -Parameter Sets: Throw -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Throw + Position: 5 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -RegularExpression -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Match, MatchExactly -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Match + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +- Name: MatchExactly + Position: 1 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Scope -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 6 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Throw -Checks if an exception was thrown. -Enclose input in a scriptblock. +Checks if an exception was thrown. Enclose input in a scriptblock. ```yaml -Type: SwitchParameter -Parameter Sets: Throw -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Management.Automation.SwitchParameter +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Throw + Position: Named + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Times -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: Invoke -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: Invoke + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### -Type -Depends on operator being used. -See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. +Depends on operator being used. See `Get-ShouldOperator -Name ` or https://pester.dev/docs/assertions/ for help. ```yaml -Type: Object -Parameter Sets: HaveParameter -Aliases: - -Required: False -Position: Named -Default value: None -Accept pipeline input: False -Accept wildcard characters: False +Type: System.Object +DefaultValue: '' +SupportsWildcards: false +Aliases: [] +ParameterSets: +- Name: HaveParameter + Position: 2 + IsRequired: false + ValueFromPipeline: false + ValueFromPipelineByPropertyName: false + ValueFromRemainingArguments: false +DontShow: false +AcceptedValues: [] +HelpMessage: '' ``` ### CommonParameters -This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, +-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS +### System.Object + ## OUTPUTS ## NOTES ## RELATED LINKS -[https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) - -[https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) +- [https://pester.dev/docs/commands/Should](https://pester.dev/docs/commands/Should) +- [https://pester.dev/docs/assertions](https://pester.dev/docs/assertions) ## VERSION -*This page was generated using comment-based help in [Pester 6.0.0-rc5](https://github.com/pester/pester).* +*This page was generated using comment-based help in [Pester 6.0.0](https://github.com/pester/pester).* diff --git a/generate-command-reference.ps1 b/generate-command-reference.ps1 index bf9733f..3770037 100644 --- a/generate-command-reference.ps1 +++ b/generate-command-reference.ps1 @@ -32,9 +32,9 @@ Write-Host 'Generating MDX files for website Command Reference' -BackgroundColor # Install required modules # ----------------------------------------------------------------------------- $ModuleList = [ordered]@{ - 'PlatyPS' = $PlatyPSVersion - 'Alt3.Docusaurus.PowerShell' = $DocusaurusVersion - 'Pester' = $PesterVersion + 'Microsoft.PowerShell.PlatyPS' = $PlatyPSVersion + 'Alt3.Docusaurus.PowerShell' = $DocusaurusVersion + 'Pester' = $PesterVersion } # Can't use the original enumerator here because we may modify the dictionary mid-process $ModuleList.Keys.Clone() | ForEach-Object { @@ -238,24 +238,24 @@ function Format-SyntaxCommonParameters { # '[]' back onto its own line where the result would exceed PlatyPS's # syntax wrap width, matching the layout PlatyPS produces without ProgressAction. # ----------------------------------------------------------------------------- -Write-Host 'Post-processing generated MDX files (ProgressAction, example fences)' -ForegroundColor Magenta -$commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docusaurusOptions.Sidebar -Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { - $content = Get-Content -LiteralPath $_.FullName -Raw - # Pull '[]' back up when removing ProgressAction would orphan it - $updated = $content -replace '[ ]*\[-ProgressAction \][ ]*\r?\n[ ]*\[\]', ' []' - # Remove any remaining ' [-ProgressAction ]' from the SYNTAX code-blocks - $updated = $updated -replace '[ ]*(\r?\n[ ]*)?\[-ProgressAction \]', '' - # Remove the dedicated '### -ProgressAction' section up to the next '### ' heading - $updated = $updated -replace '(?ms)^### -ProgressAction\r?\n.*?(?=^### )', '' - # Re-wrap '[]' onto its own line where the SYNTAX line is too long - $updated = Format-SyntaxCommonParameters -Content $updated - # Fix mismatched code fences inside the EXAMPLES section - $updated = Repair-ExampleFences -Content $updated - if ($updated -ne $content) { - Set-Content -LiteralPath $_.FullName -Value $updated -NoNewline -Encoding utf8 - } -} +# Write-Host 'Post-processing generated MDX files (ProgressAction, example fences)' -ForegroundColor Magenta +# $commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docusaurusOptions.Sidebar +# Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { +# $content = Get-Content -LiteralPath $_.FullName -Raw +# # Pull '[]' back up when removing ProgressAction would orphan it +# $updated = $content -replace '[ ]*\[-ProgressAction \][ ]*\r?\n[ ]*\[\]', ' []' +# # Remove any remaining ' [-ProgressAction ]' from the SYNTAX code-blocks +# $updated = $updated -replace '[ ]*(\r?\n[ ]*)?\[-ProgressAction \]', '' +# # Remove the dedicated '### -ProgressAction' section up to the next '### ' heading +# $updated = $updated -replace '(?ms)^### -ProgressAction\r?\n.*?(?=^### )', '' +# # Re-wrap '[]' onto its own line where the SYNTAX line is too long +# $updated = Format-SyntaxCommonParameters -Content $updated +# # Fix mismatched code fences inside the EXAMPLES section +# $updated = Repair-ExampleFences -Content $updated +# if ($updated -ne $content) { +# Set-Content -LiteralPath $_.FullName -Value $updated -NoNewline -Encoding utf8 +# } +# } Write-Host 'Render completed successfully' -BackgroundColor DarkGreen Pop-Location From 71c0f85715441958163c1cea39b18b2d018ae4c8 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Thu, 16 Jul 2026 21:00:42 +0000 Subject: [PATCH 2/6] Remove redundant post-processing --- generate-command-reference.ps1 | 66 ++++++---------------------------- 1 file changed, 10 insertions(+), 56 deletions(-) diff --git a/generate-command-reference.ps1 b/generate-command-reference.ps1 index 3770037..bbfef2c 100644 --- a/generate-command-reference.ps1 +++ b/generate-command-reference.ps1 @@ -194,68 +194,22 @@ function Repair-ExampleFences { return ($result -join $eol) } -function Format-SyntaxCommonParameters { - # After ProgressAction is removed, '[]' is collapsed back inline. - # PlatyPS keeps it inline only while the SYNTAX line stays within its wrap width - # (~110 chars, measured from prior generated output) and otherwise wraps it onto its - # own continuation line. Reproduce that so we neither leave overly long lines nor - # dangling orphans. Only lines that still carry content before the token are wrapped; - # lines that are already just ' []' are left untouched. - param([string] $Content, [int] $MaxWidth = 110) - - $eol = if ($Content -match "`r`n") { "`r`n" } else { "`n" } - $lines = $Content -split "`r?`n" - $out = [System.Collections.Generic.List[string]]::new() - foreach ($line in $lines) { - if ($line.Length -gt $MaxWidth -and $line -match '\S[ ]\[\][ ]*$') { - $head = $line -replace '[ ]*\[\][ ]*$', '' - $out.Add($head) - $out.Add(' []') - } - else { - $out.Add($line) - } - } - return ($out -join $eol) -} - # ----------------------------------------------------------------------------- # Post-process the generated MDX: -# * Strip the spurious ProgressAction common parameter that PlatyPS emits on -# PowerShell 7.4+ (https://github.com/PowerShell/platyPS/issues/663). Pester 6 -# loads a .NET 8 assembly and therefore requires PowerShell 7.4+, so the docs -# can no longer be generated on an older PowerShell to avoid this. # * Repair the mismatched code fences PlatyPS emits for .EXAMPLE blocks that # contain their own Markdown fences (see Repair-ExampleFences) so the MDX # compiles. -# The '[]' SYNTAX entry and the '### CommonParameters' section are -# kept as PlatyPS produces them. Because the ProgressAction token is longer than -# '[]' and always sits right before it, removing ProgressAction can -# leave '[]' orphaned on a wrapped continuation line. The first -# replacement handles that case by pulling '[]' back onto the line -# ProgressAction occupied; the second removes any remaining ProgressAction token, -# whether inline or wrapped onto its own line. Format-SyntaxCommonParameters then wraps -# '[]' back onto its own line where the result would exceed PlatyPS's -# syntax wrap width, matching the layout PlatyPS produces without ProgressAction. # ----------------------------------------------------------------------------- -# Write-Host 'Post-processing generated MDX files (ProgressAction, example fences)' -ForegroundColor Magenta -# $commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docusaurusOptions.Sidebar -# Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { -# $content = Get-Content -LiteralPath $_.FullName -Raw -# # Pull '[]' back up when removing ProgressAction would orphan it -# $updated = $content -replace '[ ]*\[-ProgressAction \][ ]*\r?\n[ ]*\[\]', ' []' -# # Remove any remaining ' [-ProgressAction ]' from the SYNTAX code-blocks -# $updated = $updated -replace '[ ]*(\r?\n[ ]*)?\[-ProgressAction \]', '' -# # Remove the dedicated '### -ProgressAction' section up to the next '### ' heading -# $updated = $updated -replace '(?ms)^### -ProgressAction\r?\n.*?(?=^### )', '' -# # Re-wrap '[]' onto its own line where the SYNTAX line is too long -# $updated = Format-SyntaxCommonParameters -Content $updated -# # Fix mismatched code fences inside the EXAMPLES section -# $updated = Repair-ExampleFences -Content $updated -# if ($updated -ne $content) { -# Set-Content -LiteralPath $_.FullName -Value $updated -NoNewline -Encoding utf8 -# } -# } +Write-Host 'Post-processing generated MDX files (ProgressAction, example fences)' -ForegroundColor Magenta +$commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docusaurusOptions.Sidebar +Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { + $content = Get-Content -LiteralPath $_.FullName -Raw + # Fix mismatched code fences inside the EXAMPLES section + $updated = Repair-ExampleFences -Content $content + if ($updated -ne $content) { + Set-Content -LiteralPath $_.FullName -Value $updated -NoNewline -Encoding utf8 + } +} Write-Host 'Render completed successfully' -BackgroundColor DarkGreen Pop-Location From a759f497304d27180f6b1cd6ebd92364bb9766d8 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Thu, 16 Jul 2026 21:06:39 +0000 Subject: [PATCH 3/6] Execute post-processing --- docs/commands/Set-ItResult.mdx | 2 +- docs/commands/Should-BeEquivalent.mdx | 2 -- generate-command-reference.ps1 | 10 ++-------- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/docs/commands/Set-ItResult.mdx b/docs/commands/Set-ItResult.mdx index f674cf8..6ba4c83 100644 --- a/docs/commands/Set-ItResult.mdx +++ b/docs/commands/Set-ItResult.mdx @@ -58,7 +58,7 @@ Describe "Example" { the output should be -``` +```powershell Describing Example [?] Inconclusive test is inconclusive, because we want it to be inconclusive 35ms [!] Skipped test is skipped, because we want it to be skipped 3ms diff --git a/docs/commands/Should-BeEquivalent.mdx b/docs/commands/Should-BeEquivalent.mdx index 36aab66..4af9a2b 100644 --- a/docs/commands/Should-BeEquivalent.mdx +++ b/docs/commands/Should-BeEquivalent.mdx @@ -45,10 +45,8 @@ This example generates an equivalency option object that excludes the 'Id' and ' ### EXAMPLE 2 ```powershell -```powereshell Should-BeEquivalent ... -ExcludePathsNotOnExpected ``` -``` This example generates an equivalency option object that excludes any paths not present on the expected object from the comparison, using the default deep comparison strategy. diff --git a/generate-command-reference.ps1 b/generate-command-reference.ps1 index bbfef2c..19e052e 100644 --- a/generate-command-reference.ps1 +++ b/generate-command-reference.ps1 @@ -121,13 +121,6 @@ New-DocusaurusHelp @docusaurusOptions function Repair-ExampleFences { <# - Pester's source comment-based help embeds Markdown code fences (```powershell - ... ```), including a 'powereshell' typo, inside its .EXAMPLE blocks. PlatyPS - double-wraps these, emitting mismatched fences - a bare ``` opening paired with - a ```powershell "closing" fence, sometimes doubled up. MDX 3 then mispairs the - fences, treating an example's PowerShell '@{ ... }' as a JSX expression, which - breaks the Docusaurus build ("Could not parse expression with acorn"). - Normalize fences inside the EXAMPLES section only: collapse runs of adjacent fence lines and alternate them open/close per example, so each example becomes a single well-formed ```powershell code block followed by its description. The @@ -177,7 +170,7 @@ function Repair-ExampleFences { } if (-not $inCode) { $lang = $langs | Where-Object { $_ -ne '' } | Select-Object -First 1 - if (-not $lang -or $lang -eq 'powereshell') { $lang = 'powershell' } + if (-not $lang) { $lang = 'powershell' } $result.Add('```' + $lang) $inCode = $true } @@ -205,6 +198,7 @@ $commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docu Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { $content = Get-Content -LiteralPath $_.FullName -Raw # Fix mismatched code fences inside the EXAMPLES section + # TODO: Remove? Not really needed. Only fixed two earlier typos in pester/pester repo. $updated = Repair-ExampleFences -Content $content if ($updated -ne $content) { Set-Content -LiteralPath $_.FullName -Value $updated -NoNewline -Encoding utf8 From 52f94c8941efa2caf72a60b017f2b66acb6da344 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Fri, 17 Jul 2026 09:30:58 +0000 Subject: [PATCH 4/6] Update latest preview --- docs/commands/Add-ShouldOperator.mdx | 2 +- docs/commands/AfterAll.mdx | 2 +- docs/commands/AfterEach.mdx | 2 +- docs/commands/BeforeAll.mdx | 2 +- docs/commands/BeforeDiscovery.mdx | 2 +- docs/commands/BeforeEach.mdx | 2 +- docs/commands/Context.mdx | 2 +- docs/commands/ConvertTo-JUnitReport.mdx | 2 +- docs/commands/ConvertTo-NUnitReport.mdx | 2 +- docs/commands/ConvertTo-Pester4Result.mdx | 2 +- docs/commands/Describe.mdx | 2 +- docs/commands/Export-JUnitReport.mdx | 2 +- docs/commands/Export-NUnitReport.mdx | 2 +- docs/commands/Get-ShouldOperator.mdx | 4 +- docs/commands/InModuleScope.mdx | 2 +- docs/commands/Invoke-Pester.mdx | 2 +- docs/commands/It.mdx | 2 +- docs/commands/Mock.mdx | 2 +- docs/commands/New-Fixture.mdx | 2 +- docs/commands/New-MockObject.mdx | 2 +- docs/commands/New-PesterConfiguration.mdx | 2 +- docs/commands/New-PesterContainer.mdx | 2 +- docs/commands/Set-ItResult.mdx | 2 +- docs/commands/Should-All.mdx | 2 +- docs/commands/Should-Any.mdx | 2 +- docs/commands/Should-Be.mdx | 2 +- docs/commands/Should-BeAfter.mdx | 2 +- docs/commands/Should-BeBefore.mdx | 2 +- docs/commands/Should-BeCollection.mdx | 2 +- docs/commands/Should-BeEmptyString.mdx | 2 +- docs/commands/Should-BeEquivalent.mdx | 2 +- docs/commands/Should-BeFalse.mdx | 2 +- docs/commands/Should-BeFalsy.mdx | 2 +- docs/commands/Should-BeFasterThan.mdx | 2 +- docs/commands/Should-BeGreaterThan.mdx | 2 +- docs/commands/Should-BeGreaterThanOrEqual.mdx | 2 +- docs/commands/Should-BeHashtable.mdx | 2 +- docs/commands/Should-BeLessThan.mdx | 2 +- docs/commands/Should-BeLessThanOrEqual.mdx | 2 +- docs/commands/Should-BeLikeString.mdx | 2 +- docs/commands/Should-BeNull.mdx | 2 +- docs/commands/Should-BeSame.mdx | 2 +- docs/commands/Should-BeSlowerThan.mdx | 2 +- docs/commands/Should-BeString.mdx | 2 +- docs/commands/Should-BeTrue.mdx | 2 +- docs/commands/Should-BeTruthy.mdx | 2 +- docs/commands/Should-ContainCollection.mdx | 2 +- docs/commands/Should-HaveParameter.mdx | 2 +- docs/commands/Should-HaveType.mdx | 2 +- docs/commands/Should-Invoke.mdx | 2 +- docs/commands/Should-MatchString.mdx | 2 +- docs/commands/Should-NotBe.mdx | 2 +- docs/commands/Should-NotBeEmptyString.mdx | 2 +- docs/commands/Should-NotBeLikeString.mdx | 2 +- docs/commands/Should-NotBeNull.mdx | 2 +- docs/commands/Should-NotBeSame.mdx | 2 +- docs/commands/Should-NotBeString.mdx | 2 +- .../commands/Should-NotBeWhiteSpaceString.mdx | 2 +- docs/commands/Should-NotContainCollection.mdx | 2 +- docs/commands/Should-NotHaveParameter.mdx | 2 +- docs/commands/Should-NotHaveType.mdx | 2 +- docs/commands/Should-NotInvoke.mdx | 2 +- docs/commands/Should-NotMatchString.mdx | 2 +- docs/commands/Should-Throw.mdx | 2 +- docs/commands/Should.mdx | 175 +++++++++++++++++- generate-command-reference.ps1 | 18 +- 66 files changed, 248 insertions(+), 75 deletions(-) diff --git a/docs/commands/Add-ShouldOperator.mdx b/docs/commands/Add-ShouldOperator.mdx index 9a21df2..3d4ec82 100644 --- a/docs/commands/Add-ShouldOperator.mdx +++ b/docs/commands/Add-ShouldOperator.mdx @@ -1,7 +1,7 @@ --- id: Add-ShouldOperator title: Add-ShouldOperator -description: Help page for the PowerShell Pester "Add-ShouldOperator" command +description: Help page for the PowerShell Pester 'Add-ShouldOperator' command - Register a Should Operator with Pester keywords: - PowerShell - Pester diff --git a/docs/commands/AfterAll.mdx b/docs/commands/AfterAll.mdx index 71bceb7..6f38dba 100644 --- a/docs/commands/AfterAll.mdx +++ b/docs/commands/AfterAll.mdx @@ -1,7 +1,7 @@ --- id: AfterAll title: AfterAll -description: Help page for the PowerShell Pester "AfterAll" command +description: Help page for the PowerShell Pester 'AfterAll' command - Defines a series of steps to perform at the end of the current container,Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/AfterEach.mdx b/docs/commands/AfterEach.mdx index 019a910..28d40da 100644 --- a/docs/commands/AfterEach.mdx +++ b/docs/commands/AfterEach.mdx @@ -1,7 +1,7 @@ --- id: AfterEach title: AfterEach -description: Help page for the PowerShell Pester "AfterEach" command +description: Help page for the PowerShell Pester 'AfterEach' command - Defines a series of steps to perform at the end of every It block withinthe current Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeAll.mdx b/docs/commands/BeforeAll.mdx index e2e5483..964c707 100644 --- a/docs/commands/BeforeAll.mdx +++ b/docs/commands/BeforeAll.mdx @@ -1,7 +1,7 @@ --- id: BeforeAll title: BeforeAll -description: Help page for the PowerShell Pester "BeforeAll" command +description: Help page for the PowerShell Pester 'BeforeAll' command - Defines a series of steps to perform at the beginning of the current container,Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeDiscovery.mdx b/docs/commands/BeforeDiscovery.mdx index d2d81af..8a688bc 100644 --- a/docs/commands/BeforeDiscovery.mdx +++ b/docs/commands/BeforeDiscovery.mdx @@ -1,7 +1,7 @@ --- id: BeforeDiscovery title: BeforeDiscovery -description: Help page for the PowerShell Pester "BeforeDiscovery" command +description: Help page for the PowerShell Pester 'BeforeDiscovery' command - Runs setup code that is used during Discovery phase. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeEach.mdx b/docs/commands/BeforeEach.mdx index bfc9c64..796df72 100644 --- a/docs/commands/BeforeEach.mdx +++ b/docs/commands/BeforeEach.mdx @@ -1,7 +1,7 @@ --- id: BeforeEach title: BeforeEach -description: Help page for the PowerShell Pester "BeforeEach" command +description: Help page for the PowerShell Pester 'BeforeEach' command - Defines a series of steps to perform at the beginning of every It block withinthe current Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/Context.mdx b/docs/commands/Context.mdx index 659db79..226ac9d 100644 --- a/docs/commands/Context.mdx +++ b/docs/commands/Context.mdx @@ -1,7 +1,7 @@ --- id: Context title: Context -description: Help page for the PowerShell Pester "Context" command +description: Help page for the PowerShell Pester 'Context' command - Provides logical grouping of It blocks within a single Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-JUnitReport.mdx b/docs/commands/ConvertTo-JUnitReport.mdx index 97d749c..3d887a9 100644 --- a/docs/commands/ConvertTo-JUnitReport.mdx +++ b/docs/commands/ConvertTo-JUnitReport.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-JUnitReport title: ConvertTo-JUnitReport -description: Help page for the PowerShell Pester "ConvertTo-JUnitReport" command +description: Help page for the PowerShell Pester 'ConvertTo-JUnitReport' command - Converts a Pester result-object to an JUnit-compatible XML report keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-NUnitReport.mdx b/docs/commands/ConvertTo-NUnitReport.mdx index e17e539..e433085 100644 --- a/docs/commands/ConvertTo-NUnitReport.mdx +++ b/docs/commands/ConvertTo-NUnitReport.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-NUnitReport title: ConvertTo-NUnitReport -description: Help page for the PowerShell Pester "ConvertTo-NUnitReport" command +description: Help page for the PowerShell Pester 'ConvertTo-NUnitReport' command - Converts a Pester result-object to an NUnit 2.5 or 3-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-Pester4Result.mdx b/docs/commands/ConvertTo-Pester4Result.mdx index a720534..33ff522 100644 --- a/docs/commands/ConvertTo-Pester4Result.mdx +++ b/docs/commands/ConvertTo-Pester4Result.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-Pester4Result title: ConvertTo-Pester4Result -description: Help page for the PowerShell Pester "ConvertTo-Pester4Result" command +description: Help page for the PowerShell Pester 'ConvertTo-Pester4Result' command - Converts a Pester 5 result-object to an Pester 4-compatible object keywords: - PowerShell - Pester diff --git a/docs/commands/Describe.mdx b/docs/commands/Describe.mdx index 2bfa060..aa0e499 100644 --- a/docs/commands/Describe.mdx +++ b/docs/commands/Describe.mdx @@ -1,7 +1,7 @@ --- id: Describe title: Describe -description: Help page for the PowerShell Pester "Describe" command +description: Help page for the PowerShell Pester 'Describe' command - Creates a logical group of tests. keywords: - PowerShell - Pester diff --git a/docs/commands/Export-JUnitReport.mdx b/docs/commands/Export-JUnitReport.mdx index 4f0418a..14cd8e3 100644 --- a/docs/commands/Export-JUnitReport.mdx +++ b/docs/commands/Export-JUnitReport.mdx @@ -1,7 +1,7 @@ --- id: Export-JUnitReport title: Export-JUnitReport -description: Help page for the PowerShell Pester "Export-JUnitReport" command +description: Help page for the PowerShell Pester 'Export-JUnitReport' command - Exports a Pester result-object to an JUnit-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/Export-NUnitReport.mdx b/docs/commands/Export-NUnitReport.mdx index f253732..b1e662a 100644 --- a/docs/commands/Export-NUnitReport.mdx +++ b/docs/commands/Export-NUnitReport.mdx @@ -1,7 +1,7 @@ --- id: Export-NUnitReport title: Export-NUnitReport -description: Help page for the PowerShell Pester "Export-NUnitReport" command +description: Help page for the PowerShell Pester 'Export-NUnitReport' command - Exports a Pester result-object to an NUnit-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/Get-ShouldOperator.mdx b/docs/commands/Get-ShouldOperator.mdx index e7f4510..297a8f3 100644 --- a/docs/commands/Get-ShouldOperator.mdx +++ b/docs/commands/Get-ShouldOperator.mdx @@ -1,7 +1,7 @@ --- id: Get-ShouldOperator title: Get-ShouldOperator -description: Help page for the PowerShell Pester "Get-ShouldOperator" command +description: Help page for the PowerShell Pester 'Get-ShouldOperator' command - Display the assertion operators available for use with Should. keywords: - PowerShell - Pester @@ -23,7 +23,7 @@ Display the assertion operators available for use with Should. ## SYNTAX ```powershell -Get-ShouldOperator +Get-ShouldOperator [[-Name] ] ``` ## DESCRIPTION diff --git a/docs/commands/InModuleScope.mdx b/docs/commands/InModuleScope.mdx index fba5142..a637586 100644 --- a/docs/commands/InModuleScope.mdx +++ b/docs/commands/InModuleScope.mdx @@ -1,7 +1,7 @@ --- id: InModuleScope title: InModuleScope -description: Help page for the PowerShell Pester "InModuleScope" command +description: Help page for the PowerShell Pester 'InModuleScope' command - Allows you to execute parts of a test script within thescope of a PowerShell script or manifest module. keywords: - PowerShell - Pester diff --git a/docs/commands/Invoke-Pester.mdx b/docs/commands/Invoke-Pester.mdx index 42e3296..bbabba9 100644 --- a/docs/commands/Invoke-Pester.mdx +++ b/docs/commands/Invoke-Pester.mdx @@ -1,7 +1,7 @@ --- id: Invoke-Pester title: Invoke-Pester -description: Help page for the PowerShell Pester "Invoke-Pester" command +description: Help page for the PowerShell Pester 'Invoke-Pester' command - Runs Pester tests keywords: - PowerShell - Pester diff --git a/docs/commands/It.mdx b/docs/commands/It.mdx index cb8eaf0..a190309 100644 --- a/docs/commands/It.mdx +++ b/docs/commands/It.mdx @@ -1,7 +1,7 @@ --- id: It title: It -description: Help page for the PowerShell Pester "It" command +description: Help page for the PowerShell Pester 'It' command - Validates the results of a test inside of a Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/Mock.mdx b/docs/commands/Mock.mdx index adee258..1217af8 100644 --- a/docs/commands/Mock.mdx +++ b/docs/commands/Mock.mdx @@ -1,7 +1,7 @@ --- id: Mock title: Mock -description: Help page for the PowerShell Pester "Mock" command +description: Help page for the PowerShell Pester 'Mock' command - Mocks the behavior of an existing command with an alternateimplementation. keywords: - PowerShell - Pester diff --git a/docs/commands/New-Fixture.mdx b/docs/commands/New-Fixture.mdx index 7445a92..8875133 100644 --- a/docs/commands/New-Fixture.mdx +++ b/docs/commands/New-Fixture.mdx @@ -1,7 +1,7 @@ --- id: New-Fixture title: New-Fixture -description: Help page for the PowerShell Pester "New-Fixture" command +description: Help page for the PowerShell Pester 'New-Fixture' command - This function generates two scripts, one that defines a functionand another one that contains its tests. keywords: - PowerShell - Pester diff --git a/docs/commands/New-MockObject.mdx b/docs/commands/New-MockObject.mdx index 84e2730..24930c6 100644 --- a/docs/commands/New-MockObject.mdx +++ b/docs/commands/New-MockObject.mdx @@ -1,7 +1,7 @@ --- id: New-MockObject title: New-MockObject -description: Help page for the PowerShell Pester "New-MockObject" command +description: Help page for the PowerShell Pester 'New-MockObject' command - This function instantiates a .NET object from a type. keywords: - PowerShell - Pester diff --git a/docs/commands/New-PesterConfiguration.mdx b/docs/commands/New-PesterConfiguration.mdx index ff78ccc..7d9e6d8 100644 --- a/docs/commands/New-PesterConfiguration.mdx +++ b/docs/commands/New-PesterConfiguration.mdx @@ -1,7 +1,7 @@ --- id: New-PesterConfiguration title: New-PesterConfiguration -description: Help page for the PowerShell Pester "New-PesterConfiguration" command +description: Help page for the PowerShell Pester 'New-PesterConfiguration' command - Creates a new PesterConfiguration object for advanced configuration of Invoke-Pester. keywords: - PowerShell - Pester diff --git a/docs/commands/New-PesterContainer.mdx b/docs/commands/New-PesterContainer.mdx index c234b1f..cc3d75d 100644 --- a/docs/commands/New-PesterContainer.mdx +++ b/docs/commands/New-PesterContainer.mdx @@ -1,7 +1,7 @@ --- id: New-PesterContainer title: New-PesterContainer -description: Help page for the PowerShell Pester "New-PesterContainer" command +description: Help page for the PowerShell Pester 'New-PesterContainer' command - Generates ContainerInfo-objects used as for Invoke-Pester -Container keywords: - PowerShell - Pester diff --git a/docs/commands/Set-ItResult.mdx b/docs/commands/Set-ItResult.mdx index 6ba4c83..a1b0e18 100644 --- a/docs/commands/Set-ItResult.mdx +++ b/docs/commands/Set-ItResult.mdx @@ -1,7 +1,7 @@ --- id: Set-ItResult title: Set-ItResult -description: Help page for the PowerShell Pester "Set-ItResult" command +description: Help page for the PowerShell Pester 'Set-ItResult' command - Set-ItResult is used inside the It block to explicitly set the test result keywords: - PowerShell - Pester diff --git a/docs/commands/Should-All.mdx b/docs/commands/Should-All.mdx index d3bc82a..a8b6591 100644 --- a/docs/commands/Should-All.mdx +++ b/docs/commands/Should-All.mdx @@ -1,7 +1,7 @@ --- id: Should-All title: Should-All -description: Help page for the PowerShell Pester "Should-All" command +description: Help page for the PowerShell Pester 'Should-All' command - Compares all items in a collection to a filter script. If the filter returns true, or does not throw for all the items in the collection, the assertion passes. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Any.mdx b/docs/commands/Should-Any.mdx index fa4743b..f4898b0 100644 --- a/docs/commands/Should-Any.mdx +++ b/docs/commands/Should-Any.mdx @@ -1,7 +1,7 @@ --- id: Should-Any title: Should-Any -description: Help page for the PowerShell Pester "Should-Any" command +description: Help page for the PowerShell Pester 'Should-Any' command - Compares all items in a collection to a filter script. If the filter returns true, or does not throw for any of the items in the collection, the assertion passes. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Be.mdx b/docs/commands/Should-Be.mdx index 84cc230..4f2b040 100644 --- a/docs/commands/Should-Be.mdx +++ b/docs/commands/Should-Be.mdx @@ -1,7 +1,7 @@ --- id: Should-Be title: Should-Be -description: Help page for the PowerShell Pester "Should-Be" command +description: Help page for the PowerShell Pester 'Should-Be' command - Compares the expected value to actual value, to see if they are equal. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeAfter.mdx b/docs/commands/Should-BeAfter.mdx index a7b7327..50c0dbb 100644 --- a/docs/commands/Should-BeAfter.mdx +++ b/docs/commands/Should-BeAfter.mdx @@ -1,7 +1,7 @@ --- id: Should-BeAfter title: Should-BeAfter -description: Help page for the PowerShell Pester "Should-BeAfter" command +description: Help page for the PowerShell Pester 'Should-BeAfter' command - Asserts that the provided [datetime] is after the expected [datetime]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeBefore.mdx b/docs/commands/Should-BeBefore.mdx index a44fc34..088c526 100644 --- a/docs/commands/Should-BeBefore.mdx +++ b/docs/commands/Should-BeBefore.mdx @@ -1,7 +1,7 @@ --- id: Should-BeBefore title: Should-BeBefore -description: Help page for the PowerShell Pester "Should-BeBefore" command +description: Help page for the PowerShell Pester 'Should-BeBefore' command - Asserts that the provided [datetime] is before the expected [datetime]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeCollection.mdx b/docs/commands/Should-BeCollection.mdx index 4846453..61230a4 100644 --- a/docs/commands/Should-BeCollection.mdx +++ b/docs/commands/Should-BeCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-BeCollection title: Should-BeCollection -description: Help page for the PowerShell Pester "Should-BeCollection" command +description: Help page for the PowerShell Pester 'Should-BeCollection' command - Compares collections for equality, by comparing their sizes and each item in them. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeEmptyString.mdx b/docs/commands/Should-BeEmptyString.mdx index 78e1177..76e4021 100644 --- a/docs/commands/Should-BeEmptyString.mdx +++ b/docs/commands/Should-BeEmptyString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeEmptyString title: Should-BeEmptyString -description: Help page for the PowerShell Pester "Should-BeEmptyString" command +description: Help page for the PowerShell Pester 'Should-BeEmptyString' command - Ensures that input is an empty string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeEquivalent.mdx b/docs/commands/Should-BeEquivalent.mdx index 4af9a2b..d9b1c7d 100644 --- a/docs/commands/Should-BeEquivalent.mdx +++ b/docs/commands/Should-BeEquivalent.mdx @@ -1,7 +1,7 @@ --- id: Should-BeEquivalent title: Should-BeEquivalent -description: Help page for the PowerShell Pester "Should-BeEquivalent" command +description: Help page for the PowerShell Pester 'Should-BeEquivalent' command - Compares two objects for equivalency, by recursively comparing their properties for equivalency. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFalse.mdx b/docs/commands/Should-BeFalse.mdx index d1049cb..f86661c 100644 --- a/docs/commands/Should-BeFalse.mdx +++ b/docs/commands/Should-BeFalse.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFalse title: Should-BeFalse -description: Help page for the PowerShell Pester "Should-BeFalse" command +description: Help page for the PowerShell Pester 'Should-BeFalse' command - Compares the actual value to a boolean $false. It does not convert input values to boolean, and will fail for any value that is not $false. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFalsy.mdx b/docs/commands/Should-BeFalsy.mdx index 9a1c31b..e0ddd78 100644 --- a/docs/commands/Should-BeFalsy.mdx +++ b/docs/commands/Should-BeFalsy.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFalsy title: Should-BeFalsy -description: Help page for the PowerShell Pester "Should-BeFalsy" command +description: "Help page for the PowerShell Pester 'Should-BeFalsy' command - Compares the actual value to a boolean $false or a falsy value: 0, \"\", $null or @(). It converts the input value to a boolean." keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFasterThan.mdx b/docs/commands/Should-BeFasterThan.mdx index 150a278..6be9f83 100644 --- a/docs/commands/Should-BeFasterThan.mdx +++ b/docs/commands/Should-BeFasterThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFasterThan title: Should-BeFasterThan -description: Help page for the PowerShell Pester "Should-BeFasterThan" command +description: Help page for the PowerShell Pester 'Should-BeFasterThan' command - Asserts that the provided [timespan] or [scriptblock] is faster than the expected [timespan]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeGreaterThan.mdx b/docs/commands/Should-BeGreaterThan.mdx index 52d36fb..c9df522 100644 --- a/docs/commands/Should-BeGreaterThan.mdx +++ b/docs/commands/Should-BeGreaterThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeGreaterThan title: Should-BeGreaterThan -description: Help page for the PowerShell Pester "Should-BeGreaterThan" command +description: Help page for the PowerShell Pester 'Should-BeGreaterThan' command - Compares the expected value to actual value, to see if the actual value is greater than the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeGreaterThanOrEqual.mdx b/docs/commands/Should-BeGreaterThanOrEqual.mdx index ef63714..ae759ae 100644 --- a/docs/commands/Should-BeGreaterThanOrEqual.mdx +++ b/docs/commands/Should-BeGreaterThanOrEqual.mdx @@ -1,7 +1,7 @@ --- id: Should-BeGreaterThanOrEqual title: Should-BeGreaterThanOrEqual -description: Help page for the PowerShell Pester "Should-BeGreaterThanOrEqual" command +description: Help page for the PowerShell Pester 'Should-BeGreaterThanOrEqual' command - Compares the expected value to actual value, to see if the actual value is greater than or equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeHashtable.mdx b/docs/commands/Should-BeHashtable.mdx index 64e9943..d92effa 100644 --- a/docs/commands/Should-BeHashtable.mdx +++ b/docs/commands/Should-BeHashtable.mdx @@ -1,7 +1,7 @@ --- id: Should-BeHashtable title: Should-BeHashtable -description: Help page for the PowerShell Pester "Should-BeHashtable" command +description: Help page for the PowerShell Pester 'Should-BeHashtable' command - Asserts that the input is a hashtable or dictionary, and optionally checks the number ofentries, whether it is ordered, and that it contains specific keys. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLessThan.mdx b/docs/commands/Should-BeLessThan.mdx index d508a1a..09cffa4 100644 --- a/docs/commands/Should-BeLessThan.mdx +++ b/docs/commands/Should-BeLessThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLessThan title: Should-BeLessThan -description: Help page for the PowerShell Pester "Should-BeLessThan" command +description: Help page for the PowerShell Pester 'Should-BeLessThan' command - Compares the expected value to actual value, to see if the actual value is less than the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLessThanOrEqual.mdx b/docs/commands/Should-BeLessThanOrEqual.mdx index db9b456..a33ea2b 100644 --- a/docs/commands/Should-BeLessThanOrEqual.mdx +++ b/docs/commands/Should-BeLessThanOrEqual.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLessThanOrEqual title: Should-BeLessThanOrEqual -description: Help page for the PowerShell Pester "Should-BeLessThanOrEqual" command +description: Help page for the PowerShell Pester 'Should-BeLessThanOrEqual' command - Compares the expected value to actual value, to see if the actual value is less than or equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLikeString.mdx b/docs/commands/Should-BeLikeString.mdx index 02c3239..c790e64 100644 --- a/docs/commands/Should-BeLikeString.mdx +++ b/docs/commands/Should-BeLikeString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLikeString title: Should-BeLikeString -description: Help page for the PowerShell Pester "Should-BeLikeString" command +description: Help page for the PowerShell Pester 'Should-BeLikeString' command - Asserts that the actual value is like the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeNull.mdx b/docs/commands/Should-BeNull.mdx index b78c796..ee96e48 100644 --- a/docs/commands/Should-BeNull.mdx +++ b/docs/commands/Should-BeNull.mdx @@ -1,7 +1,7 @@ --- id: Should-BeNull title: Should-BeNull -description: Help page for the PowerShell Pester "Should-BeNull" command +description: Help page for the PowerShell Pester 'Should-BeNull' command - Asserts that the input is `$null`. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeSame.mdx b/docs/commands/Should-BeSame.mdx index ef64674..8339e95 100644 --- a/docs/commands/Should-BeSame.mdx +++ b/docs/commands/Should-BeSame.mdx @@ -1,7 +1,7 @@ --- id: Should-BeSame title: Should-BeSame -description: Help page for the PowerShell Pester "Should-BeSame" command +description: Help page for the PowerShell Pester 'Should-BeSame' command - Compares the expected value to actual value, to see if they are the same instance. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeSlowerThan.mdx b/docs/commands/Should-BeSlowerThan.mdx index 2991baa..4cc7b3b 100644 --- a/docs/commands/Should-BeSlowerThan.mdx +++ b/docs/commands/Should-BeSlowerThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeSlowerThan title: Should-BeSlowerThan -description: Help page for the PowerShell Pester "Should-BeSlowerThan" command +description: Help page for the PowerShell Pester 'Should-BeSlowerThan' command - Asserts that the provided [timespan] is slower than the expected [timespan]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeString.mdx b/docs/commands/Should-BeString.mdx index b26c485..e49f2ce 100644 --- a/docs/commands/Should-BeString.mdx +++ b/docs/commands/Should-BeString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeString title: Should-BeString -description: Help page for the PowerShell Pester "Should-BeString" command +description: Help page for the PowerShell Pester 'Should-BeString' command - Asserts that the actual value is equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeTrue.mdx b/docs/commands/Should-BeTrue.mdx index f6c3ff1..5abdec9 100644 --- a/docs/commands/Should-BeTrue.mdx +++ b/docs/commands/Should-BeTrue.mdx @@ -1,7 +1,7 @@ --- id: Should-BeTrue title: Should-BeTrue -description: Help page for the PowerShell Pester "Should-BeTrue" command +description: Help page for the PowerShell Pester 'Should-BeTrue' command - Compares the actual value to a boolean $true. It does not convert input values to boolean, and will fail for any value is not $true. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeTruthy.mdx b/docs/commands/Should-BeTruthy.mdx index b9ce2c4..4e4c5f4 100644 --- a/docs/commands/Should-BeTruthy.mdx +++ b/docs/commands/Should-BeTruthy.mdx @@ -1,7 +1,7 @@ --- id: Should-BeTruthy title: Should-BeTruthy -description: Help page for the PowerShell Pester "Should-BeTruthy" command +description: Help page for the PowerShell Pester 'Should-BeTruthy' command - Compares the actual value to a boolean $true. It converts input values to boolean, and will fail for any value is not $true, or truthy. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-ContainCollection.mdx b/docs/commands/Should-ContainCollection.mdx index b621d87..1a6402f 100644 --- a/docs/commands/Should-ContainCollection.mdx +++ b/docs/commands/Should-ContainCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-ContainCollection title: Should-ContainCollection -description: Help page for the PowerShell Pester "Should-ContainCollection" command +description: Help page for the PowerShell Pester 'Should-ContainCollection' command - Checks that the expected collection is present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-HaveParameter.mdx b/docs/commands/Should-HaveParameter.mdx index 3508010..effaaa9 100644 --- a/docs/commands/Should-HaveParameter.mdx +++ b/docs/commands/Should-HaveParameter.mdx @@ -1,7 +1,7 @@ --- id: Should-HaveParameter title: Should-HaveParameter -description: Help page for the PowerShell Pester "Should-HaveParameter" command +description: Help page for the PowerShell Pester 'Should-HaveParameter' command - Asserts that a command has the expected parameter. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-HaveType.mdx b/docs/commands/Should-HaveType.mdx index 32c0eb6..678fbb6 100644 --- a/docs/commands/Should-HaveType.mdx +++ b/docs/commands/Should-HaveType.mdx @@ -1,7 +1,7 @@ --- id: Should-HaveType title: Should-HaveType -description: Help page for the PowerShell Pester "Should-HaveType" command +description: Help page for the PowerShell Pester 'Should-HaveType' command - Asserts that the input is of the expected type. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Invoke.mdx b/docs/commands/Should-Invoke.mdx index 4b301ea..5b3a77f 100644 --- a/docs/commands/Should-Invoke.mdx +++ b/docs/commands/Should-Invoke.mdx @@ -1,7 +1,7 @@ --- id: Should-Invoke title: Should-Invoke -description: Help page for the PowerShell Pester "Should-Invoke" command +description: Help page for the PowerShell Pester 'Should-Invoke' command - Checks if a Mocked command has been called a certain number of timesand throws an exception if it has not. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-MatchString.mdx b/docs/commands/Should-MatchString.mdx index b39f5b6..956675f 100644 --- a/docs/commands/Should-MatchString.mdx +++ b/docs/commands/Should-MatchString.mdx @@ -1,7 +1,7 @@ --- id: Should-MatchString title: Should-MatchString -description: Help page for the PowerShell Pester "Should-MatchString" command +description: Help page for the PowerShell Pester 'Should-MatchString' command - Tests whether a string matches a regular expression pattern. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBe.mdx b/docs/commands/Should-NotBe.mdx index c35b1f9..7965dff 100644 --- a/docs/commands/Should-NotBe.mdx +++ b/docs/commands/Should-NotBe.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBe title: Should-NotBe -description: Help page for the PowerShell Pester "Should-NotBe" command +description: Help page for the PowerShell Pester 'Should-NotBe' command - Compares the expected value to actual value, to see if they are not equal. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeEmptyString.mdx b/docs/commands/Should-NotBeEmptyString.mdx index 07754da..82b8538 100644 --- a/docs/commands/Should-NotBeEmptyString.mdx +++ b/docs/commands/Should-NotBeEmptyString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeEmptyString title: Should-NotBeEmptyString -description: Help page for the PowerShell Pester "Should-NotBeEmptyString" command +description: Help page for the PowerShell Pester 'Should-NotBeEmptyString' command - Ensures that the input is a string, and that the input is not $null or empty string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeLikeString.mdx b/docs/commands/Should-NotBeLikeString.mdx index 30d27ed..fc9a7d3 100644 --- a/docs/commands/Should-NotBeLikeString.mdx +++ b/docs/commands/Should-NotBeLikeString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeLikeString title: Should-NotBeLikeString -description: Help page for the PowerShell Pester "Should-NotBeLikeString" command +description: Help page for the PowerShell Pester 'Should-NotBeLikeString' command - Asserts that the actual value is not like the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeNull.mdx b/docs/commands/Should-NotBeNull.mdx index 6d7ab24..a94cc8c 100644 --- a/docs/commands/Should-NotBeNull.mdx +++ b/docs/commands/Should-NotBeNull.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeNull title: Should-NotBeNull -description: Help page for the PowerShell Pester "Should-NotBeNull" command +description: Help page for the PowerShell Pester 'Should-NotBeNull' command - Asserts that the input is not `$null`. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeSame.mdx b/docs/commands/Should-NotBeSame.mdx index fc09cb6..44402df 100644 --- a/docs/commands/Should-NotBeSame.mdx +++ b/docs/commands/Should-NotBeSame.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeSame title: Should-NotBeSame -description: Help page for the PowerShell Pester "Should-NotBeSame" command +description: Help page for the PowerShell Pester 'Should-NotBeSame' command - Compares the expected value to actual value, to see if the actual value is not the same instance as the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeString.mdx b/docs/commands/Should-NotBeString.mdx index 2fd4a7a..14e3b7b 100644 --- a/docs/commands/Should-NotBeString.mdx +++ b/docs/commands/Should-NotBeString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeString title: Should-NotBeString -description: Help page for the PowerShell Pester "Should-NotBeString" command +description: Help page for the PowerShell Pester 'Should-NotBeString' command - Asserts that the actual value is not equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeWhiteSpaceString.mdx b/docs/commands/Should-NotBeWhiteSpaceString.mdx index ac8a008..43a7bdd 100644 --- a/docs/commands/Should-NotBeWhiteSpaceString.mdx +++ b/docs/commands/Should-NotBeWhiteSpaceString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeWhiteSpaceString title: Should-NotBeWhiteSpaceString -description: Help page for the PowerShell Pester "Should-NotBeWhiteSpaceString" command +description: Help page for the PowerShell Pester 'Should-NotBeWhiteSpaceString' command - Ensures that the input is a string, and that the input is not $null, empty, or whitespace only string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotContainCollection.mdx b/docs/commands/Should-NotContainCollection.mdx index 629b9c4..d14ff60 100644 --- a/docs/commands/Should-NotContainCollection.mdx +++ b/docs/commands/Should-NotContainCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-NotContainCollection title: Should-NotContainCollection -description: Help page for the PowerShell Pester "Should-NotContainCollection" command +description: Help page for the PowerShell Pester 'Should-NotContainCollection' command - Checks that the expected collection is not present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotHaveParameter.mdx b/docs/commands/Should-NotHaveParameter.mdx index e14bf85..44c39be 100644 --- a/docs/commands/Should-NotHaveParameter.mdx +++ b/docs/commands/Should-NotHaveParameter.mdx @@ -1,7 +1,7 @@ --- id: Should-NotHaveParameter title: Should-NotHaveParameter -description: Help page for the PowerShell Pester "Should-NotHaveParameter" command +description: Help page for the PowerShell Pester 'Should-NotHaveParameter' command - Asserts that a command has does not have the parameter. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotHaveType.mdx b/docs/commands/Should-NotHaveType.mdx index 5a2dc35..abf4456 100644 --- a/docs/commands/Should-NotHaveType.mdx +++ b/docs/commands/Should-NotHaveType.mdx @@ -1,7 +1,7 @@ --- id: Should-NotHaveType title: Should-NotHaveType -description: Help page for the PowerShell Pester "Should-NotHaveType" command +description: Help page for the PowerShell Pester 'Should-NotHaveType' command - Asserts that the input is not of the expected type. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotInvoke.mdx b/docs/commands/Should-NotInvoke.mdx index 61112a4..69c5aaa 100644 --- a/docs/commands/Should-NotInvoke.mdx +++ b/docs/commands/Should-NotInvoke.mdx @@ -1,7 +1,7 @@ --- id: Should-NotInvoke title: Should-NotInvoke -description: Help page for the PowerShell Pester "Should-NotInvoke" command +description: Help page for the PowerShell Pester 'Should-NotInvoke' command - Checks that mocked command was not called and throws exception if it was. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotMatchString.mdx b/docs/commands/Should-NotMatchString.mdx index 5e79fd9..1ea2e3d 100644 --- a/docs/commands/Should-NotMatchString.mdx +++ b/docs/commands/Should-NotMatchString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotMatchString title: Should-NotMatchString -description: Help page for the PowerShell Pester "Should-NotMatchString" command +description: Help page for the PowerShell Pester 'Should-NotMatchString' command - Tests whether a string does not match a regular expression pattern. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Throw.mdx b/docs/commands/Should-Throw.mdx index dfd5c9b..df1b747 100644 --- a/docs/commands/Should-Throw.mdx +++ b/docs/commands/Should-Throw.mdx @@ -1,7 +1,7 @@ --- id: Should-Throw title: Should-Throw -description: Help page for the PowerShell Pester "Should-Throw" command +description: Help page for the PowerShell Pester 'Should-Throw' command - Asserts that a script block throws an exception. keywords: - PowerShell - Pester diff --git a/docs/commands/Should.mdx b/docs/commands/Should.mdx index f3f0de2..d4860c1 100644 --- a/docs/commands/Should.mdx +++ b/docs/commands/Should.mdx @@ -1,7 +1,7 @@ --- id: Should title: Should -description: Help page for the PowerShell Pester "Should" command +description: Help page for the PowerShell Pester 'Should' command - Should is a keyword that is used to define an assertion inside an It block. keywords: - PowerShell - Pester @@ -22,8 +22,179 @@ Should is a keyword that is used to define an assertion inside an It block. ## SYNTAX +### Be + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Be] [-Not] +``` + +### BeExactly + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeExactly] +``` + +### BeGreaterThan + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeGreaterThan] +``` + +### BeLessOrEqual + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeLessOrEqual] +``` + +### BeIn + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] [-BeIn] +``` + +### BeLessThan + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeLessThan] +``` + +### BeGreaterOrEqual + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeGreaterOrEqual] +``` + +### BeLike + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] [-BeLike] +``` + +### BeLikeExactly + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-BeLikeExactly] +``` + +### BeNullOrEmpty + +```powershell +Should [[-ActualValue] ] [[-Because] ] [-Not] [-BeNullOrEmpty] +``` + +### BeOfType + +```powershell +Should [[-ActualValue] ] [[-ExpectedType] ] [[-Because] ] [-Not] [-BeOfType] +``` + +### BeTrue + +```powershell +Should [[-ActualValue] ] [[-Because] ] [-Not] [-BeTrue] +``` + +### BeFalse + +```powershell +Should [[-ActualValue] ] [[-Because] ] [-Not] [-BeFalse] +``` + +### Contain + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] [-Contain] +``` + +### Exist + +```powershell +Should [[-ActualValue] ] [[-Because] ] [-LiteralPath] [-Not] [-Exist] +``` + +### FileContentMatch + +```powershell +Should [[-ActualValue] ] [[-ExpectedContent] ] [[-Because] ] [-Not] + [-FileContentMatch] +``` + +### FileContentMatchExactly + +```powershell +Should [[-ActualValue] ] [[-ExpectedContent] ] [[-Because] ] [-Not] + [-FileContentMatchExactly] +``` + +### FileContentMatchMultiline + +```powershell +Should [[-ActualValue] ] [[-ExpectedContent] ] [[-Because] ] [-Not] + [-FileContentMatchMultiline] +``` + +### FileContentMatchMultilineExactly + +```powershell +Should [[-ActualValue] ] [[-ExpectedContent] ] [[-Because] ] [-Not] + [-FileContentMatchMultilineExactly] +``` + +### HaveCount + +```powershell +Should [[-ActualValue] ] [[-ExpectedValue] ] [[-Because] ] [-Not] + [-HaveCount] +``` + +### HaveParameter + +```powershell +Should [[-ActualValue] ] [[-ParameterName] ] [[-Type] ] + [[-DefaultValue] ] [-Mandatory] [[-InParameterSet] ] [-HasArgumentCompleter] + [[-Alias] ] [[-Because] ] [-Not] [-HaveParameter] +``` + +### Match + +```powershell +Should [[-ActualValue] ] [[-RegularExpression] ] [[-Because] ] [-Not] + [-Match] +``` + +### MatchExactly + +```powershell +Should [[-ActualValue] ] [[-RegularExpression] ] [[-Because] ] [-Not] + [-MatchExactly] +``` + +### Throw + +```powershell +Should [[-ActualValue] ] [[-ExpectedMessage] ] [[-ErrorId] ] + [[-ExceptionType] ] [[-Because] ] [-PassThru] [-Not] [-Throw] +``` + +### InvokeVerifiable + +```powershell +Should [[-ActualValue] ] [[-Because] ] [-Not] [-InvokeVerifiable] +``` + +### Invoke + ```powershell -Should [[-ActualValue] ] +Should [[-ActualValue] ] [[-CommandName] ] [[-Times] ] + [[-ParameterFilter] ] [[-ExclusiveFilter] ] [[-ModuleName] ] + [[-Scope] ] [-Exactly] [[-Because] ] [[-CallerSessionState] ] + [[-CommandDisplayName] ] [-Not] [-Invoke] ``` ## DESCRIPTION diff --git a/generate-command-reference.ps1 b/generate-command-reference.ps1 index 19e052e..9446f77 100644 --- a/generate-command-reference.ps1 +++ b/generate-command-reference.ps1 @@ -23,8 +23,8 @@ param ( [ValidateSet('Current','v4','v5')] [string] $DocsVersion = 'Current' ) -Set-StrictMode -Version Latest -$PSDefaultParameterValues['*:ErrorAction'] = 'Stop' +# Set-StrictMode -Version Latest +# $PSDefaultParameterValues['*:ErrorAction'] = 'Stop' Write-Host 'Generating MDX files for website Command Reference' -BackgroundColor DarkGreen @@ -32,9 +32,9 @@ Write-Host 'Generating MDX files for website Command Reference' -BackgroundColor # Install required modules # ----------------------------------------------------------------------------- $ModuleList = [ordered]@{ - 'Microsoft.PowerShell.PlatyPS' = $PlatyPSVersion - 'Alt3.Docusaurus.PowerShell' = $DocusaurusVersion - 'Pester' = $PesterVersion + 'Microsoft.PowerShell.PlatyPS' = $PlatyPSVersion + 'Alt3.Docusaurus.PowerShell' = $DocusaurusVersion + 'Pester' = $PesterVersion } # Can't use the original enumerator here because we may modify the dictionary mid-process $ModuleList.Keys.Clone() | ForEach-Object { @@ -72,7 +72,6 @@ $ModuleList.Keys.Clone() | ForEach-Object { # Use below settings to manipulate the rendered MDX files # ----------------------------------------------------------------------------- $docusaurusOptions = @{ - Module = 'Pester' DocsFolder = switch ($DocsVersion) { 'Current' { "$PSScriptRoot/docs" } 'v5' { "$PSScriptRoot/versioned_docs/version-v5" } @@ -86,7 +85,6 @@ $docusaurusOptions = @{ 'SafeGetCommand' 'Set-DynamicParameterVariable' ) - MetaDescription = 'Help page for the PowerShell Pester "%1" command' MetaKeywords = @( 'PowerShell' 'Pester' @@ -117,7 +115,11 @@ if (Test-Path -Path $outputFolder) { } Write-Host 'Generating new MDX files' -ForegroundColor Magenta -New-DocusaurusHelp @docusaurusOptions +$commandHelp = New-CommandHelp -CommandInfo (Get-Command -Module Pester -CommandType Cmdlet, Function) +$commandHelp | ForEach-Object { + $_.Metadata['description'] = "Help page for the PowerShell Pester '$($_.Title)' command - $($_.Synopsis.ReplaceLineEndings(''))" +} +New-DocusaurusHelp @docusaurusOptions -CommandHelp $commandHelp function Repair-ExampleFences { <# From 9a858eb94d98d6e7f0c78edea5b67de9900115d7 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Fri, 17 Jul 2026 14:07:46 +0000 Subject: [PATCH 5/6] Use Alt3.Docusaurus.PowerShell 2.0 GA and update opengraph description with synopsis --- docs/commands/Add-ShouldOperator.mdx | 2 +- docs/commands/AfterAll.mdx | 2 +- docs/commands/AfterEach.mdx | 2 +- docs/commands/BeforeAll.mdx | 2 +- docs/commands/BeforeDiscovery.mdx | 2 +- docs/commands/BeforeEach.mdx | 2 +- docs/commands/Context.mdx | 2 +- docs/commands/ConvertTo-JUnitReport.mdx | 2 +- docs/commands/ConvertTo-NUnitReport.mdx | 2 +- docs/commands/ConvertTo-Pester4Result.mdx | 2 +- docs/commands/Describe.mdx | 2 +- docs/commands/Export-JUnitReport.mdx | 2 +- docs/commands/Export-NUnitReport.mdx | 2 +- docs/commands/Get-ShouldOperator.mdx | 2 +- docs/commands/InModuleScope.mdx | 2 +- docs/commands/Invoke-Pester.mdx | 2 +- docs/commands/It.mdx | 2 +- docs/commands/Mock.mdx | 2 +- docs/commands/New-Fixture.mdx | 2 +- docs/commands/New-MockObject.mdx | 2 +- docs/commands/New-PesterConfiguration.mdx | 2 +- docs/commands/New-PesterContainer.mdx | 2 +- docs/commands/Set-ItResult.mdx | 2 +- docs/commands/Should-All.mdx | 2 +- docs/commands/Should-Any.mdx | 2 +- docs/commands/Should-Be.mdx | 2 +- docs/commands/Should-BeAfter.mdx | 2 +- docs/commands/Should-BeBefore.mdx | 2 +- docs/commands/Should-BeCollection.mdx | 2 +- docs/commands/Should-BeEmptyString.mdx | 2 +- docs/commands/Should-BeEquivalent.mdx | 2 +- docs/commands/Should-BeFalse.mdx | 2 +- docs/commands/Should-BeFalsy.mdx | 2 +- docs/commands/Should-BeFasterThan.mdx | 2 +- docs/commands/Should-BeGreaterThan.mdx | 2 +- docs/commands/Should-BeGreaterThanOrEqual.mdx | 2 +- docs/commands/Should-BeHashtable.mdx | 2 +- docs/commands/Should-BeLessThan.mdx | 2 +- docs/commands/Should-BeLessThanOrEqual.mdx | 2 +- docs/commands/Should-BeLikeString.mdx | 2 +- docs/commands/Should-BeNull.mdx | 2 +- docs/commands/Should-BeSame.mdx | 2 +- docs/commands/Should-BeSlowerThan.mdx | 2 +- docs/commands/Should-BeString.mdx | 2 +- docs/commands/Should-BeTrue.mdx | 2 +- docs/commands/Should-BeTruthy.mdx | 2 +- docs/commands/Should-ContainCollection.mdx | 2 +- docs/commands/Should-HaveParameter.mdx | 2 +- docs/commands/Should-HaveType.mdx | 2 +- docs/commands/Should-Invoke.mdx | 2 +- docs/commands/Should-MatchString.mdx | 2 +- docs/commands/Should-NotBe.mdx | 2 +- docs/commands/Should-NotBeEmptyString.mdx | 2 +- docs/commands/Should-NotBeLikeString.mdx | 2 +- docs/commands/Should-NotBeNull.mdx | 2 +- docs/commands/Should-NotBeSame.mdx | 2 +- docs/commands/Should-NotBeString.mdx | 2 +- .../commands/Should-NotBeWhiteSpaceString.mdx | 2 +- docs/commands/Should-NotContainCollection.mdx | 2 +- docs/commands/Should-NotHaveParameter.mdx | 2 +- docs/commands/Should-NotHaveType.mdx | 2 +- docs/commands/Should-NotInvoke.mdx | 2 +- docs/commands/Should-NotMatchString.mdx | 2 +- docs/commands/Should-Throw.mdx | 2 +- docs/commands/Should.mdx | 2 +- docs/commands/docusaurus.sidebar.js | 2 +- generate-command-reference.ps1 | 38 ++++++++++++++----- 67 files changed, 94 insertions(+), 76 deletions(-) diff --git a/docs/commands/Add-ShouldOperator.mdx b/docs/commands/Add-ShouldOperator.mdx index 3d4ec82..7ec0625 100644 --- a/docs/commands/Add-ShouldOperator.mdx +++ b/docs/commands/Add-ShouldOperator.mdx @@ -1,7 +1,7 @@ --- id: Add-ShouldOperator title: Add-ShouldOperator -description: Help page for the PowerShell Pester 'Add-ShouldOperator' command - Register a Should Operator with Pester +description: Help for Pester command 'Add-ShouldOperator'. Register a Should Operator with Pester keywords: - PowerShell - Pester diff --git a/docs/commands/AfterAll.mdx b/docs/commands/AfterAll.mdx index 6f38dba..b2b9578 100644 --- a/docs/commands/AfterAll.mdx +++ b/docs/commands/AfterAll.mdx @@ -1,7 +1,7 @@ --- id: AfterAll title: AfterAll -description: Help page for the PowerShell Pester 'AfterAll' command - Defines a series of steps to perform at the end of the current container,Context or Describe block. +description: Help for Pester command 'AfterAll'. Defines a series of steps to perform at the end of the current container, Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/AfterEach.mdx b/docs/commands/AfterEach.mdx index 28d40da..98380eb 100644 --- a/docs/commands/AfterEach.mdx +++ b/docs/commands/AfterEach.mdx @@ -1,7 +1,7 @@ --- id: AfterEach title: AfterEach -description: Help page for the PowerShell Pester 'AfterEach' command - Defines a series of steps to perform at the end of every It block withinthe current Context or Describe block. +description: Help for Pester command 'AfterEach'. Defines a series of steps to perform at the end of every It block within the current Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeAll.mdx b/docs/commands/BeforeAll.mdx index 964c707..a4b61aa 100644 --- a/docs/commands/BeforeAll.mdx +++ b/docs/commands/BeforeAll.mdx @@ -1,7 +1,7 @@ --- id: BeforeAll title: BeforeAll -description: Help page for the PowerShell Pester 'BeforeAll' command - Defines a series of steps to perform at the beginning of the current container,Context or Describe block. +description: Help for Pester command 'BeforeAll'. Defines a series of steps to perform at the beginning of the current container, Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeDiscovery.mdx b/docs/commands/BeforeDiscovery.mdx index 8a688bc..f88a8ef 100644 --- a/docs/commands/BeforeDiscovery.mdx +++ b/docs/commands/BeforeDiscovery.mdx @@ -1,7 +1,7 @@ --- id: BeforeDiscovery title: BeforeDiscovery -description: Help page for the PowerShell Pester 'BeforeDiscovery' command - Runs setup code that is used during Discovery phase. +description: Help for Pester command 'BeforeDiscovery'. Runs setup code that is used during Discovery phase. keywords: - PowerShell - Pester diff --git a/docs/commands/BeforeEach.mdx b/docs/commands/BeforeEach.mdx index 796df72..f3b3ad2 100644 --- a/docs/commands/BeforeEach.mdx +++ b/docs/commands/BeforeEach.mdx @@ -1,7 +1,7 @@ --- id: BeforeEach title: BeforeEach -description: Help page for the PowerShell Pester 'BeforeEach' command - Defines a series of steps to perform at the beginning of every It block withinthe current Context or Describe block. +description: Help for Pester command 'BeforeEach'. Defines a series of steps to perform at the beginning of every It block within the current Context or Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/Context.mdx b/docs/commands/Context.mdx index 226ac9d..a51631e 100644 --- a/docs/commands/Context.mdx +++ b/docs/commands/Context.mdx @@ -1,7 +1,7 @@ --- id: Context title: Context -description: Help page for the PowerShell Pester 'Context' command - Provides logical grouping of It blocks within a single Describe block. +description: Help for Pester command 'Context'. Provides logical grouping of It blocks within a single Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-JUnitReport.mdx b/docs/commands/ConvertTo-JUnitReport.mdx index 3d887a9..e75f9ae 100644 --- a/docs/commands/ConvertTo-JUnitReport.mdx +++ b/docs/commands/ConvertTo-JUnitReport.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-JUnitReport title: ConvertTo-JUnitReport -description: Help page for the PowerShell Pester 'ConvertTo-JUnitReport' command - Converts a Pester result-object to an JUnit-compatible XML report +description: Help for Pester command 'ConvertTo-JUnitReport'. Converts a Pester result-object to an JUnit-compatible XML report keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-NUnitReport.mdx b/docs/commands/ConvertTo-NUnitReport.mdx index e433085..981465c 100644 --- a/docs/commands/ConvertTo-NUnitReport.mdx +++ b/docs/commands/ConvertTo-NUnitReport.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-NUnitReport title: ConvertTo-NUnitReport -description: Help page for the PowerShell Pester 'ConvertTo-NUnitReport' command - Converts a Pester result-object to an NUnit 2.5 or 3-compatible XML-report +description: Help for Pester command 'ConvertTo-NUnitReport'. Converts a Pester result-object to an NUnit 2.5 or 3-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/ConvertTo-Pester4Result.mdx b/docs/commands/ConvertTo-Pester4Result.mdx index 33ff522..a8c39ef 100644 --- a/docs/commands/ConvertTo-Pester4Result.mdx +++ b/docs/commands/ConvertTo-Pester4Result.mdx @@ -1,7 +1,7 @@ --- id: ConvertTo-Pester4Result title: ConvertTo-Pester4Result -description: Help page for the PowerShell Pester 'ConvertTo-Pester4Result' command - Converts a Pester 5 result-object to an Pester 4-compatible object +description: Help for Pester command 'ConvertTo-Pester4Result'. Converts a Pester 5 result-object to an Pester 4-compatible object keywords: - PowerShell - Pester diff --git a/docs/commands/Describe.mdx b/docs/commands/Describe.mdx index aa0e499..52a1eb7 100644 --- a/docs/commands/Describe.mdx +++ b/docs/commands/Describe.mdx @@ -1,7 +1,7 @@ --- id: Describe title: Describe -description: Help page for the PowerShell Pester 'Describe' command - Creates a logical group of tests. +description: Help for Pester command 'Describe'. Creates a logical group of tests. keywords: - PowerShell - Pester diff --git a/docs/commands/Export-JUnitReport.mdx b/docs/commands/Export-JUnitReport.mdx index 14cd8e3..a8892d7 100644 --- a/docs/commands/Export-JUnitReport.mdx +++ b/docs/commands/Export-JUnitReport.mdx @@ -1,7 +1,7 @@ --- id: Export-JUnitReport title: Export-JUnitReport -description: Help page for the PowerShell Pester 'Export-JUnitReport' command - Exports a Pester result-object to an JUnit-compatible XML-report +description: Help for Pester command 'Export-JUnitReport'. Exports a Pester result-object to an JUnit-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/Export-NUnitReport.mdx b/docs/commands/Export-NUnitReport.mdx index b1e662a..108f76d 100644 --- a/docs/commands/Export-NUnitReport.mdx +++ b/docs/commands/Export-NUnitReport.mdx @@ -1,7 +1,7 @@ --- id: Export-NUnitReport title: Export-NUnitReport -description: Help page for the PowerShell Pester 'Export-NUnitReport' command - Exports a Pester result-object to an NUnit-compatible XML-report +description: Help for Pester command 'Export-NUnitReport'. Exports a Pester result-object to an NUnit-compatible XML-report keywords: - PowerShell - Pester diff --git a/docs/commands/Get-ShouldOperator.mdx b/docs/commands/Get-ShouldOperator.mdx index 297a8f3..b75b6ae 100644 --- a/docs/commands/Get-ShouldOperator.mdx +++ b/docs/commands/Get-ShouldOperator.mdx @@ -1,7 +1,7 @@ --- id: Get-ShouldOperator title: Get-ShouldOperator -description: Help page for the PowerShell Pester 'Get-ShouldOperator' command - Display the assertion operators available for use with Should. +description: Help for Pester command 'Get-ShouldOperator'. Display the assertion operators available for use with Should. keywords: - PowerShell - Pester diff --git a/docs/commands/InModuleScope.mdx b/docs/commands/InModuleScope.mdx index a637586..e83d321 100644 --- a/docs/commands/InModuleScope.mdx +++ b/docs/commands/InModuleScope.mdx @@ -1,7 +1,7 @@ --- id: InModuleScope title: InModuleScope -description: Help page for the PowerShell Pester 'InModuleScope' command - Allows you to execute parts of a test script within thescope of a PowerShell script or manifest module. +description: Help for Pester command 'InModuleScope'. Allows you to execute parts of a test script within the scope of a PowerShell script or manifest module. keywords: - PowerShell - Pester diff --git a/docs/commands/Invoke-Pester.mdx b/docs/commands/Invoke-Pester.mdx index bbabba9..63b3e85 100644 --- a/docs/commands/Invoke-Pester.mdx +++ b/docs/commands/Invoke-Pester.mdx @@ -1,7 +1,7 @@ --- id: Invoke-Pester title: Invoke-Pester -description: Help page for the PowerShell Pester 'Invoke-Pester' command - Runs Pester tests +description: Help for Pester command 'Invoke-Pester'. Runs Pester tests keywords: - PowerShell - Pester diff --git a/docs/commands/It.mdx b/docs/commands/It.mdx index a190309..5286d51 100644 --- a/docs/commands/It.mdx +++ b/docs/commands/It.mdx @@ -1,7 +1,7 @@ --- id: It title: It -description: Help page for the PowerShell Pester 'It' command - Validates the results of a test inside of a Describe block. +description: Help for Pester command 'It'. Validates the results of a test inside of a Describe block. keywords: - PowerShell - Pester diff --git a/docs/commands/Mock.mdx b/docs/commands/Mock.mdx index 1217af8..ea15e29 100644 --- a/docs/commands/Mock.mdx +++ b/docs/commands/Mock.mdx @@ -1,7 +1,7 @@ --- id: Mock title: Mock -description: Help page for the PowerShell Pester 'Mock' command - Mocks the behavior of an existing command with an alternateimplementation. +description: Help for Pester command 'Mock'. Mocks the behavior of an existing command with an alternate implementation. keywords: - PowerShell - Pester diff --git a/docs/commands/New-Fixture.mdx b/docs/commands/New-Fixture.mdx index 8875133..af70279 100644 --- a/docs/commands/New-Fixture.mdx +++ b/docs/commands/New-Fixture.mdx @@ -1,7 +1,7 @@ --- id: New-Fixture title: New-Fixture -description: Help page for the PowerShell Pester 'New-Fixture' command - This function generates two scripts, one that defines a functionand another one that contains its tests. +description: Help for Pester command 'New-Fixture'. This function generates two scripts, one that defines a function and another one that contains its tests. keywords: - PowerShell - Pester diff --git a/docs/commands/New-MockObject.mdx b/docs/commands/New-MockObject.mdx index 24930c6..30aa709 100644 --- a/docs/commands/New-MockObject.mdx +++ b/docs/commands/New-MockObject.mdx @@ -1,7 +1,7 @@ --- id: New-MockObject title: New-MockObject -description: Help page for the PowerShell Pester 'New-MockObject' command - This function instantiates a .NET object from a type. +description: Help for Pester command 'New-MockObject'. This function instantiates a .NET object from a type. keywords: - PowerShell - Pester diff --git a/docs/commands/New-PesterConfiguration.mdx b/docs/commands/New-PesterConfiguration.mdx index 7d9e6d8..6cf8562 100644 --- a/docs/commands/New-PesterConfiguration.mdx +++ b/docs/commands/New-PesterConfiguration.mdx @@ -1,7 +1,7 @@ --- id: New-PesterConfiguration title: New-PesterConfiguration -description: Help page for the PowerShell Pester 'New-PesterConfiguration' command - Creates a new PesterConfiguration object for advanced configuration of Invoke-Pester. +description: Help for Pester command 'New-PesterConfiguration'. Creates a new PesterConfiguration object for advanced configuration of Invoke-Pester. keywords: - PowerShell - Pester diff --git a/docs/commands/New-PesterContainer.mdx b/docs/commands/New-PesterContainer.mdx index cc3d75d..67a4c93 100644 --- a/docs/commands/New-PesterContainer.mdx +++ b/docs/commands/New-PesterContainer.mdx @@ -1,7 +1,7 @@ --- id: New-PesterContainer title: New-PesterContainer -description: Help page for the PowerShell Pester 'New-PesterContainer' command - Generates ContainerInfo-objects used as for Invoke-Pester -Container +description: Help for Pester command 'New-PesterContainer'. Generates ContainerInfo-objects used as for Invoke-Pester -Container keywords: - PowerShell - Pester diff --git a/docs/commands/Set-ItResult.mdx b/docs/commands/Set-ItResult.mdx index a1b0e18..f5cdeed 100644 --- a/docs/commands/Set-ItResult.mdx +++ b/docs/commands/Set-ItResult.mdx @@ -1,7 +1,7 @@ --- id: Set-ItResult title: Set-ItResult -description: Help page for the PowerShell Pester 'Set-ItResult' command - Set-ItResult is used inside the It block to explicitly set the test result +description: Help for Pester command 'Set-ItResult'. Set-ItResult is used inside the It block to explicitly set the test result keywords: - PowerShell - Pester diff --git a/docs/commands/Should-All.mdx b/docs/commands/Should-All.mdx index a8b6591..b349f58 100644 --- a/docs/commands/Should-All.mdx +++ b/docs/commands/Should-All.mdx @@ -1,7 +1,7 @@ --- id: Should-All title: Should-All -description: Help page for the PowerShell Pester 'Should-All' command - Compares all items in a collection to a filter script. If the filter returns true, or does not throw for all the items in the collection, the assertion passes. +description: Help for Pester command 'Should-All'. Compares all items in a collection to a filter script. If the filter returns true, or does not throw for all the items in the collection, the assertion passes. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Any.mdx b/docs/commands/Should-Any.mdx index f4898b0..876323c 100644 --- a/docs/commands/Should-Any.mdx +++ b/docs/commands/Should-Any.mdx @@ -1,7 +1,7 @@ --- id: Should-Any title: Should-Any -description: Help page for the PowerShell Pester 'Should-Any' command - Compares all items in a collection to a filter script. If the filter returns true, or does not throw for any of the items in the collection, the assertion passes. +description: Help for Pester command 'Should-Any'. Compares all items in a collection to a filter script. If the filter returns true, or does not throw for any of the items in the collection, the assertion passes. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Be.mdx b/docs/commands/Should-Be.mdx index 4f2b040..a8cbdf1 100644 --- a/docs/commands/Should-Be.mdx +++ b/docs/commands/Should-Be.mdx @@ -1,7 +1,7 @@ --- id: Should-Be title: Should-Be -description: Help page for the PowerShell Pester 'Should-Be' command - Compares the expected value to actual value, to see if they are equal. +description: Help for Pester command 'Should-Be'. Compares the expected value to actual value, to see if they are equal. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeAfter.mdx b/docs/commands/Should-BeAfter.mdx index 50c0dbb..271ae26 100644 --- a/docs/commands/Should-BeAfter.mdx +++ b/docs/commands/Should-BeAfter.mdx @@ -1,7 +1,7 @@ --- id: Should-BeAfter title: Should-BeAfter -description: Help page for the PowerShell Pester 'Should-BeAfter' command - Asserts that the provided [datetime] is after the expected [datetime]. +description: Help for Pester command 'Should-BeAfter'. Asserts that the provided [datetime] is after the expected [datetime]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeBefore.mdx b/docs/commands/Should-BeBefore.mdx index 088c526..b09849c 100644 --- a/docs/commands/Should-BeBefore.mdx +++ b/docs/commands/Should-BeBefore.mdx @@ -1,7 +1,7 @@ --- id: Should-BeBefore title: Should-BeBefore -description: Help page for the PowerShell Pester 'Should-BeBefore' command - Asserts that the provided [datetime] is before the expected [datetime]. +description: Help for Pester command 'Should-BeBefore'. Asserts that the provided [datetime] is before the expected [datetime]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeCollection.mdx b/docs/commands/Should-BeCollection.mdx index 61230a4..185d5dd 100644 --- a/docs/commands/Should-BeCollection.mdx +++ b/docs/commands/Should-BeCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-BeCollection title: Should-BeCollection -description: Help page for the PowerShell Pester 'Should-BeCollection' command - Compares collections for equality, by comparing their sizes and each item in them. It does not compare the types of the input collections. +description: Help for Pester command 'Should-BeCollection'. Compares collections for equality, by comparing their sizes and each item in them. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeEmptyString.mdx b/docs/commands/Should-BeEmptyString.mdx index 76e4021..1700d6f 100644 --- a/docs/commands/Should-BeEmptyString.mdx +++ b/docs/commands/Should-BeEmptyString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeEmptyString title: Should-BeEmptyString -description: Help page for the PowerShell Pester 'Should-BeEmptyString' command - Ensures that input is an empty string. +description: Help for Pester command 'Should-BeEmptyString'. Ensures that input is an empty string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeEquivalent.mdx b/docs/commands/Should-BeEquivalent.mdx index d9b1c7d..ebfcf5f 100644 --- a/docs/commands/Should-BeEquivalent.mdx +++ b/docs/commands/Should-BeEquivalent.mdx @@ -1,7 +1,7 @@ --- id: Should-BeEquivalent title: Should-BeEquivalent -description: Help page for the PowerShell Pester 'Should-BeEquivalent' command - Compares two objects for equivalency, by recursively comparing their properties for equivalency. +description: Help for Pester command 'Should-BeEquivalent'. Compares two objects for equivalency, by recursively comparing their properties for equivalency. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFalse.mdx b/docs/commands/Should-BeFalse.mdx index f86661c..1aa59de 100644 --- a/docs/commands/Should-BeFalse.mdx +++ b/docs/commands/Should-BeFalse.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFalse title: Should-BeFalse -description: Help page for the PowerShell Pester 'Should-BeFalse' command - Compares the actual value to a boolean $false. It does not convert input values to boolean, and will fail for any value that is not $false. +description: Help for Pester command 'Should-BeFalse'. Compares the actual value to a boolean $false. It does not convert input values to boolean, and will fail for any value that is not $false. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFalsy.mdx b/docs/commands/Should-BeFalsy.mdx index e0ddd78..b75e522 100644 --- a/docs/commands/Should-BeFalsy.mdx +++ b/docs/commands/Should-BeFalsy.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFalsy title: Should-BeFalsy -description: "Help page for the PowerShell Pester 'Should-BeFalsy' command - Compares the actual value to a boolean $false or a falsy value: 0, \"\", $null or @(). It converts the input value to a boolean." +description: "Help for Pester command 'Should-BeFalsy'. Compares the actual value to a boolean $false or a falsy value: 0, \"\", $null or @(). It converts the input value to a boolean." keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeFasterThan.mdx b/docs/commands/Should-BeFasterThan.mdx index 6be9f83..d88fb34 100644 --- a/docs/commands/Should-BeFasterThan.mdx +++ b/docs/commands/Should-BeFasterThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeFasterThan title: Should-BeFasterThan -description: Help page for the PowerShell Pester 'Should-BeFasterThan' command - Asserts that the provided [timespan] or [scriptblock] is faster than the expected [timespan]. +description: Help for Pester command 'Should-BeFasterThan'. Asserts that the provided [timespan] or [scriptblock] is faster than the expected [timespan]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeGreaterThan.mdx b/docs/commands/Should-BeGreaterThan.mdx index c9df522..933f91c 100644 --- a/docs/commands/Should-BeGreaterThan.mdx +++ b/docs/commands/Should-BeGreaterThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeGreaterThan title: Should-BeGreaterThan -description: Help page for the PowerShell Pester 'Should-BeGreaterThan' command - Compares the expected value to actual value, to see if the actual value is greater than the expected value. +description: Help for Pester command 'Should-BeGreaterThan'. Compares the expected value to actual value, to see if the actual value is greater than the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeGreaterThanOrEqual.mdx b/docs/commands/Should-BeGreaterThanOrEqual.mdx index ae759ae..3267f92 100644 --- a/docs/commands/Should-BeGreaterThanOrEqual.mdx +++ b/docs/commands/Should-BeGreaterThanOrEqual.mdx @@ -1,7 +1,7 @@ --- id: Should-BeGreaterThanOrEqual title: Should-BeGreaterThanOrEqual -description: Help page for the PowerShell Pester 'Should-BeGreaterThanOrEqual' command - Compares the expected value to actual value, to see if the actual value is greater than or equal to the expected value. +description: Help for Pester command 'Should-BeGreaterThanOrEqual'. Compares the expected value to actual value, to see if the actual value is greater than or equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeHashtable.mdx b/docs/commands/Should-BeHashtable.mdx index d92effa..91d9059 100644 --- a/docs/commands/Should-BeHashtable.mdx +++ b/docs/commands/Should-BeHashtable.mdx @@ -1,7 +1,7 @@ --- id: Should-BeHashtable title: Should-BeHashtable -description: Help page for the PowerShell Pester 'Should-BeHashtable' command - Asserts that the input is a hashtable or dictionary, and optionally checks the number ofentries, whether it is ordered, and that it contains specific keys. +description: Help for Pester command 'Should-BeHashtable'. Asserts that the input is a hashtable or dictionary, and optionally checks the number of entries, whether it is ordered, and that it contains specific keys. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLessThan.mdx b/docs/commands/Should-BeLessThan.mdx index 09cffa4..32db545 100644 --- a/docs/commands/Should-BeLessThan.mdx +++ b/docs/commands/Should-BeLessThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLessThan title: Should-BeLessThan -description: Help page for the PowerShell Pester 'Should-BeLessThan' command - Compares the expected value to actual value, to see if the actual value is less than the expected value. +description: Help for Pester command 'Should-BeLessThan'. Compares the expected value to actual value, to see if the actual value is less than the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLessThanOrEqual.mdx b/docs/commands/Should-BeLessThanOrEqual.mdx index a33ea2b..eac8902 100644 --- a/docs/commands/Should-BeLessThanOrEqual.mdx +++ b/docs/commands/Should-BeLessThanOrEqual.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLessThanOrEqual title: Should-BeLessThanOrEqual -description: Help page for the PowerShell Pester 'Should-BeLessThanOrEqual' command - Compares the expected value to actual value, to see if the actual value is less than or equal to the expected value. +description: Help for Pester command 'Should-BeLessThanOrEqual'. Compares the expected value to actual value, to see if the actual value is less than or equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeLikeString.mdx b/docs/commands/Should-BeLikeString.mdx index c790e64..bb2f274 100644 --- a/docs/commands/Should-BeLikeString.mdx +++ b/docs/commands/Should-BeLikeString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeLikeString title: Should-BeLikeString -description: Help page for the PowerShell Pester 'Should-BeLikeString' command - Asserts that the actual value is like the expected value. +description: Help for Pester command 'Should-BeLikeString'. Asserts that the actual value is like the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeNull.mdx b/docs/commands/Should-BeNull.mdx index ee96e48..558b16d 100644 --- a/docs/commands/Should-BeNull.mdx +++ b/docs/commands/Should-BeNull.mdx @@ -1,7 +1,7 @@ --- id: Should-BeNull title: Should-BeNull -description: Help page for the PowerShell Pester 'Should-BeNull' command - Asserts that the input is `$null`. +description: Help for Pester command 'Should-BeNull'. Asserts that the input is `$null`. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeSame.mdx b/docs/commands/Should-BeSame.mdx index 8339e95..c9d89cf 100644 --- a/docs/commands/Should-BeSame.mdx +++ b/docs/commands/Should-BeSame.mdx @@ -1,7 +1,7 @@ --- id: Should-BeSame title: Should-BeSame -description: Help page for the PowerShell Pester 'Should-BeSame' command - Compares the expected value to actual value, to see if they are the same instance. +description: Help for Pester command 'Should-BeSame'. Compares the expected value to actual value, to see if they are the same instance. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeSlowerThan.mdx b/docs/commands/Should-BeSlowerThan.mdx index 4cc7b3b..f7ff668 100644 --- a/docs/commands/Should-BeSlowerThan.mdx +++ b/docs/commands/Should-BeSlowerThan.mdx @@ -1,7 +1,7 @@ --- id: Should-BeSlowerThan title: Should-BeSlowerThan -description: Help page for the PowerShell Pester 'Should-BeSlowerThan' command - Asserts that the provided [timespan] is slower than the expected [timespan]. +description: Help for Pester command 'Should-BeSlowerThan'. Asserts that the provided [timespan] is slower than the expected [timespan]. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeString.mdx b/docs/commands/Should-BeString.mdx index e49f2ce..6fd24ab 100644 --- a/docs/commands/Should-BeString.mdx +++ b/docs/commands/Should-BeString.mdx @@ -1,7 +1,7 @@ --- id: Should-BeString title: Should-BeString -description: Help page for the PowerShell Pester 'Should-BeString' command - Asserts that the actual value is equal to the expected value. +description: Help for Pester command 'Should-BeString'. Asserts that the actual value is equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeTrue.mdx b/docs/commands/Should-BeTrue.mdx index 5abdec9..08ea846 100644 --- a/docs/commands/Should-BeTrue.mdx +++ b/docs/commands/Should-BeTrue.mdx @@ -1,7 +1,7 @@ --- id: Should-BeTrue title: Should-BeTrue -description: Help page for the PowerShell Pester 'Should-BeTrue' command - Compares the actual value to a boolean $true. It does not convert input values to boolean, and will fail for any value is not $true. +description: Help for Pester command 'Should-BeTrue'. Compares the actual value to a boolean $true. It does not convert input values to boolean, and will fail for any value is not $true. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-BeTruthy.mdx b/docs/commands/Should-BeTruthy.mdx index 4e4c5f4..42c00b8 100644 --- a/docs/commands/Should-BeTruthy.mdx +++ b/docs/commands/Should-BeTruthy.mdx @@ -1,7 +1,7 @@ --- id: Should-BeTruthy title: Should-BeTruthy -description: Help page for the PowerShell Pester 'Should-BeTruthy' command - Compares the actual value to a boolean $true. It converts input values to boolean, and will fail for any value is not $true, or truthy. +description: Help for Pester command 'Should-BeTruthy'. Compares the actual value to a boolean $true. It converts input values to boolean, and will fail for any value is not $true, or truthy. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-ContainCollection.mdx b/docs/commands/Should-ContainCollection.mdx index 1a6402f..760fb90 100644 --- a/docs/commands/Should-ContainCollection.mdx +++ b/docs/commands/Should-ContainCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-ContainCollection title: Should-ContainCollection -description: Help page for the PowerShell Pester 'Should-ContainCollection' command - Checks that the expected collection is present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. +description: Help for Pester command 'Should-ContainCollection'. Checks that the expected collection is present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-HaveParameter.mdx b/docs/commands/Should-HaveParameter.mdx index effaaa9..9ab5eb9 100644 --- a/docs/commands/Should-HaveParameter.mdx +++ b/docs/commands/Should-HaveParameter.mdx @@ -1,7 +1,7 @@ --- id: Should-HaveParameter title: Should-HaveParameter -description: Help page for the PowerShell Pester 'Should-HaveParameter' command - Asserts that a command has the expected parameter. +description: Help for Pester command 'Should-HaveParameter'. Asserts that a command has the expected parameter. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-HaveType.mdx b/docs/commands/Should-HaveType.mdx index 678fbb6..b93a043 100644 --- a/docs/commands/Should-HaveType.mdx +++ b/docs/commands/Should-HaveType.mdx @@ -1,7 +1,7 @@ --- id: Should-HaveType title: Should-HaveType -description: Help page for the PowerShell Pester 'Should-HaveType' command - Asserts that the input is of the expected type. +description: Help for Pester command 'Should-HaveType'. Asserts that the input is of the expected type. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Invoke.mdx b/docs/commands/Should-Invoke.mdx index 5b3a77f..c2a7a15 100644 --- a/docs/commands/Should-Invoke.mdx +++ b/docs/commands/Should-Invoke.mdx @@ -1,7 +1,7 @@ --- id: Should-Invoke title: Should-Invoke -description: Help page for the PowerShell Pester 'Should-Invoke' command - Checks if a Mocked command has been called a certain number of timesand throws an exception if it has not. +description: Help for Pester command 'Should-Invoke'. Checks if a Mocked command has been called a certain number of times and throws an exception if it has not. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-MatchString.mdx b/docs/commands/Should-MatchString.mdx index 956675f..f9f7117 100644 --- a/docs/commands/Should-MatchString.mdx +++ b/docs/commands/Should-MatchString.mdx @@ -1,7 +1,7 @@ --- id: Should-MatchString title: Should-MatchString -description: Help page for the PowerShell Pester 'Should-MatchString' command - Tests whether a string matches a regular expression pattern. +description: Help for Pester command 'Should-MatchString'. Tests whether a string matches a regular expression pattern. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBe.mdx b/docs/commands/Should-NotBe.mdx index 7965dff..09b4495 100644 --- a/docs/commands/Should-NotBe.mdx +++ b/docs/commands/Should-NotBe.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBe title: Should-NotBe -description: Help page for the PowerShell Pester 'Should-NotBe' command - Compares the expected value to actual value, to see if they are not equal. +description: Help for Pester command 'Should-NotBe'. Compares the expected value to actual value, to see if they are not equal. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeEmptyString.mdx b/docs/commands/Should-NotBeEmptyString.mdx index 82b8538..4460c30 100644 --- a/docs/commands/Should-NotBeEmptyString.mdx +++ b/docs/commands/Should-NotBeEmptyString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeEmptyString title: Should-NotBeEmptyString -description: Help page for the PowerShell Pester 'Should-NotBeEmptyString' command - Ensures that the input is a string, and that the input is not $null or empty string. +description: Help for Pester command 'Should-NotBeEmptyString'. Ensures that the input is a string, and that the input is not $null or empty string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeLikeString.mdx b/docs/commands/Should-NotBeLikeString.mdx index fc9a7d3..baf2c1f 100644 --- a/docs/commands/Should-NotBeLikeString.mdx +++ b/docs/commands/Should-NotBeLikeString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeLikeString title: Should-NotBeLikeString -description: Help page for the PowerShell Pester 'Should-NotBeLikeString' command - Asserts that the actual value is not like the expected value. +description: Help for Pester command 'Should-NotBeLikeString'. Asserts that the actual value is not like the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeNull.mdx b/docs/commands/Should-NotBeNull.mdx index a94cc8c..cb4c7af 100644 --- a/docs/commands/Should-NotBeNull.mdx +++ b/docs/commands/Should-NotBeNull.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeNull title: Should-NotBeNull -description: Help page for the PowerShell Pester 'Should-NotBeNull' command - Asserts that the input is not `$null`. +description: Help for Pester command 'Should-NotBeNull'. Asserts that the input is not `$null`. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeSame.mdx b/docs/commands/Should-NotBeSame.mdx index 44402df..466dda1 100644 --- a/docs/commands/Should-NotBeSame.mdx +++ b/docs/commands/Should-NotBeSame.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeSame title: Should-NotBeSame -description: Help page for the PowerShell Pester 'Should-NotBeSame' command - Compares the expected value to actual value, to see if the actual value is not the same instance as the expected value. +description: Help for Pester command 'Should-NotBeSame'. Compares the expected value to actual value, to see if the actual value is not the same instance as the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeString.mdx b/docs/commands/Should-NotBeString.mdx index 14e3b7b..bd1259f 100644 --- a/docs/commands/Should-NotBeString.mdx +++ b/docs/commands/Should-NotBeString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeString title: Should-NotBeString -description: Help page for the PowerShell Pester 'Should-NotBeString' command - Asserts that the actual value is not equal to the expected value. +description: Help for Pester command 'Should-NotBeString'. Asserts that the actual value is not equal to the expected value. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotBeWhiteSpaceString.mdx b/docs/commands/Should-NotBeWhiteSpaceString.mdx index 43a7bdd..14790ae 100644 --- a/docs/commands/Should-NotBeWhiteSpaceString.mdx +++ b/docs/commands/Should-NotBeWhiteSpaceString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotBeWhiteSpaceString title: Should-NotBeWhiteSpaceString -description: Help page for the PowerShell Pester 'Should-NotBeWhiteSpaceString' command - Ensures that the input is a string, and that the input is not $null, empty, or whitespace only string. +description: Help for Pester command 'Should-NotBeWhiteSpaceString'. Ensures that the input is a string, and that the input is not $null, empty, or whitespace only string. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotContainCollection.mdx b/docs/commands/Should-NotContainCollection.mdx index d14ff60..8784fde 100644 --- a/docs/commands/Should-NotContainCollection.mdx +++ b/docs/commands/Should-NotContainCollection.mdx @@ -1,7 +1,7 @@ --- id: Should-NotContainCollection title: Should-NotContainCollection -description: Help page for the PowerShell Pester 'Should-NotContainCollection' command - Checks that the expected collection is not present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. +description: Help for Pester command 'Should-NotContainCollection'. Checks that the expected collection is not present in the actual collection as an ordered subsequence. It does not compare the types of the input collections. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotHaveParameter.mdx b/docs/commands/Should-NotHaveParameter.mdx index 44c39be..b0a118d 100644 --- a/docs/commands/Should-NotHaveParameter.mdx +++ b/docs/commands/Should-NotHaveParameter.mdx @@ -1,7 +1,7 @@ --- id: Should-NotHaveParameter title: Should-NotHaveParameter -description: Help page for the PowerShell Pester 'Should-NotHaveParameter' command - Asserts that a command has does not have the parameter. +description: Help for Pester command 'Should-NotHaveParameter'. Asserts that a command has does not have the parameter. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotHaveType.mdx b/docs/commands/Should-NotHaveType.mdx index abf4456..6ae4e71 100644 --- a/docs/commands/Should-NotHaveType.mdx +++ b/docs/commands/Should-NotHaveType.mdx @@ -1,7 +1,7 @@ --- id: Should-NotHaveType title: Should-NotHaveType -description: Help page for the PowerShell Pester 'Should-NotHaveType' command - Asserts that the input is not of the expected type. +description: Help for Pester command 'Should-NotHaveType'. Asserts that the input is not of the expected type. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotInvoke.mdx b/docs/commands/Should-NotInvoke.mdx index 69c5aaa..57713ce 100644 --- a/docs/commands/Should-NotInvoke.mdx +++ b/docs/commands/Should-NotInvoke.mdx @@ -1,7 +1,7 @@ --- id: Should-NotInvoke title: Should-NotInvoke -description: Help page for the PowerShell Pester 'Should-NotInvoke' command - Checks that mocked command was not called and throws exception if it was. +description: Help for Pester command 'Should-NotInvoke'. Checks that mocked command was not called and throws exception if it was. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-NotMatchString.mdx b/docs/commands/Should-NotMatchString.mdx index 1ea2e3d..5550cb6 100644 --- a/docs/commands/Should-NotMatchString.mdx +++ b/docs/commands/Should-NotMatchString.mdx @@ -1,7 +1,7 @@ --- id: Should-NotMatchString title: Should-NotMatchString -description: Help page for the PowerShell Pester 'Should-NotMatchString' command - Tests whether a string does not match a regular expression pattern. +description: Help for Pester command 'Should-NotMatchString'. Tests whether a string does not match a regular expression pattern. keywords: - PowerShell - Pester diff --git a/docs/commands/Should-Throw.mdx b/docs/commands/Should-Throw.mdx index df1b747..ca117e5 100644 --- a/docs/commands/Should-Throw.mdx +++ b/docs/commands/Should-Throw.mdx @@ -1,7 +1,7 @@ --- id: Should-Throw title: Should-Throw -description: Help page for the PowerShell Pester 'Should-Throw' command - Asserts that a script block throws an exception. +description: Help for Pester command 'Should-Throw'. Asserts that a script block throws an exception. keywords: - PowerShell - Pester diff --git a/docs/commands/Should.mdx b/docs/commands/Should.mdx index d4860c1..57ae88a 100644 --- a/docs/commands/Should.mdx +++ b/docs/commands/Should.mdx @@ -1,7 +1,7 @@ --- id: Should title: Should -description: Help page for the PowerShell Pester 'Should' command - Should is a keyword that is used to define an assertion inside an It block. +description: Help for Pester command 'Should'. Should is a keyword that is used to define an assertion inside an It block. keywords: - PowerShell - Pester diff --git a/docs/commands/docusaurus.sidebar.js b/docs/commands/docusaurus.sidebar.js index 58ff74d..a8d1ee1 100644 --- a/docs/commands/docusaurus.sidebar.js +++ b/docs/commands/docusaurus.sidebar.js @@ -1,7 +1,7 @@ /** * Import this file in your Docusaurus `sidebars.js` file. * - * Auto-generated by Alt3.Docusaurus.Powershell 1.0.37. + * Auto-generated by Alt3.Docusaurus.Powershell 2.0.0. * * Copyright (c) 2019-present, ALT3 B.V. * diff --git a/generate-command-reference.ps1 b/generate-command-reference.ps1 index 9446f77..4516080 100644 --- a/generate-command-reference.ps1 +++ b/generate-command-reference.ps1 @@ -8,8 +8,17 @@ .EXAMPLE .\generate-command-reference.ps1 + Update current (latest) docs using latest Pester version + + .EXAMPLE + .\generate-command-reference.ps1 -PesterVersion 6.0.0 + + Update current (latest) docs using Pester 6.0.0 explicitly + .EXAMPLE - .\generate-command-reference.ps1 -PesterVersion 4.10.1 + .\generate-command-reference.ps1 -PesterVersion 5.9.0 -DocsVersion v5 + + Update versioned docs for v5 using explicit version 5.9.0 .LINK https://docusaurus-powershell.netlify.app/docs/faq/ci-cd @@ -23,10 +32,10 @@ param ( [ValidateSet('Current','v4','v5')] [string] $DocsVersion = 'Current' ) -# Set-StrictMode -Version Latest -# $PSDefaultParameterValues['*:ErrorAction'] = 'Stop' +Set-StrictMode -Version Latest +$PSDefaultParameterValues['*:ErrorAction'] = 'Stop' -Write-Host 'Generating MDX files for website Command Reference' -BackgroundColor DarkGreen +Write-Host 'Generating MDX files for Command Reference-section of website' -BackgroundColor DarkGreen # ----------------------------------------------------------------------------- # Install required modules @@ -68,10 +77,23 @@ $ModuleList.Keys.Clone() | ForEach-Object { } } +Write-Host 'Pre-processing CommandHelp-objects' -ForegroundColor Magenta +$commandHelp = & { + # Workaround: Strict mode breaks PlatyPS (https://github.com/PowerShell/platyPS/issues/800) + Set-StrictMode -Off + New-CommandHelp -CommandInfo (Get-Command -Module Pester -CommandType Cmdlet, Function) +} +$commandHelp | ForEach-Object { + # Customize the description metadata for each command to include the synopsis + # Synopsis is guaranteed by Help.Tests.ps1 in pester/pester-repo, so not checking for "Fill in ..." placeholders + $_.Metadata['description'] = "Help for Pester command '$($_.Title)'. $($_.Synopsis -replace '\s+', ' ')" +} + # ----------------------------------------------------------------------------- # Use below settings to manipulate the rendered MDX files # ----------------------------------------------------------------------------- $docusaurusOptions = @{ + CommandHelp = $commandHelp DocsFolder = switch ($DocsVersion) { 'Current' { "$PSScriptRoot/docs" } 'v5' { "$PSScriptRoot/versioned_docs/version-v5" } @@ -115,11 +137,7 @@ if (Test-Path -Path $outputFolder) { } Write-Host 'Generating new MDX files' -ForegroundColor Magenta -$commandHelp = New-CommandHelp -CommandInfo (Get-Command -Module Pester -CommandType Cmdlet, Function) -$commandHelp | ForEach-Object { - $_.Metadata['description'] = "Help page for the PowerShell Pester '$($_.Title)' command - $($_.Synopsis.ReplaceLineEndings(''))" -} -New-DocusaurusHelp @docusaurusOptions -CommandHelp $commandHelp +New-DocusaurusHelp @docusaurusOptions function Repair-ExampleFences { <# @@ -195,7 +213,7 @@ function Repair-ExampleFences { # contain their own Markdown fences (see Repair-ExampleFences) so the MDX # compiles. # ----------------------------------------------------------------------------- -Write-Host 'Post-processing generated MDX files (ProgressAction, example fences)' -ForegroundColor Magenta +Write-Host 'Post-processing generated MDX files' -ForegroundColor Magenta $commandsFolder = Join-Path -Path $docusaurusOptions.DocsFolder -ChildPath $docusaurusOptions.Sidebar Get-ChildItem -Path $commandsFolder -Filter '*.mdx' | ForEach-Object { $content = Get-Content -LiteralPath $_.FullName -Raw From 6a39f2ba421d6c2c9e0f25dfd320702560b6cae1 Mon Sep 17 00:00:00 2001 From: Frode Flaten <3436158+fflaten@users.noreply.github.com> Date: Fri, 17 Jul 2026 14:27:50 +0000 Subject: [PATCH 6/6] Remove template logo --- static/img/logo.svg | 1 - static/img/undraw_docusaurus_mountain.svg | 170 ---------------------- static/img/undraw_docusaurus_react.svg | 169 --------------------- static/img/undraw_docusaurus_tree.svg | 1 - 4 files changed, 341 deletions(-) delete mode 100644 static/img/logo.svg delete mode 100644 static/img/undraw_docusaurus_mountain.svg delete mode 100644 static/img/undraw_docusaurus_react.svg delete mode 100644 static/img/undraw_docusaurus_tree.svg diff --git a/static/img/logo.svg b/static/img/logo.svg deleted file mode 100644 index 9db6d0d..0000000 --- a/static/img/logo.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/img/undraw_docusaurus_mountain.svg b/static/img/undraw_docusaurus_mountain.svg deleted file mode 100644 index 431cef2..0000000 --- a/static/img/undraw_docusaurus_mountain.svg +++ /dev/null @@ -1,170 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/static/img/undraw_docusaurus_react.svg b/static/img/undraw_docusaurus_react.svg deleted file mode 100644 index e417050..0000000 --- a/static/img/undraw_docusaurus_react.svg +++ /dev/null @@ -1,169 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/static/img/undraw_docusaurus_tree.svg b/static/img/undraw_docusaurus_tree.svg deleted file mode 100644 index a05cc03..0000000 --- a/static/img/undraw_docusaurus_tree.svg +++ /dev/null @@ -1 +0,0 @@ -docu_tree \ No newline at end of file