| external help file | PSPublishModule-help.xml |
|---|---|
| Module Name | PSPublishModule |
| online version | https://github.com/EvotecIT/PSPublishModule |
| schema | 2.0.0 |
Analyzes and summarizes failed Pester tests from either a Pester results object or an NUnit XML result file.
Get-ModuleTestFailures [-Path <string>] [-ProjectPath <string>] [-OutputFormat <ModuleTestFailureOutputFormat>] [-ShowSuccessful] [-PassThru] [<CommonParameters>]Get-ModuleTestFailures -TestResults <Object> [-ProjectPath <string>] [-OutputFormat <ModuleTestFailureOutputFormat>] [-ShowSuccessful] [-PassThru] [<CommonParameters>]This cmdlet is designed to make CI output and local troubleshooting easier by summarizing failures from:
Use -OutputFormat to control whether the cmdlet writes a concise host summary, detailed messages, or emits JSON to the pipeline.
PS> Get-ModuleTestFailuresSearches for TestResults.xml under the project and prints a detailed failure report.
PS> Get-ModuleTestFailures -Path 'Tests\TestResults.xml' -OutputFormat SummaryWrites a compact summary that is suitable for CI logs.
PS> Invoke-ModuleTestSuite -ProjectPath 'C:\Git\MyModule' | Get-ModuleTestFailures -OutputFormat Detailed -PassThruUses the in-memory results and returns the analysis object for further processing.
Format for displaying test failures.
Type: ModuleTestFailureOutputFormat
Parameter Sets: Path, TestResults
Aliases: None
Possible values: Summary, Detailed, Json
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueReturn the failure analysis object for further processing.
Type: SwitchParameter
Parameter Sets: Path, TestResults
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TruePath to the NUnit XML test results file. If not specified, searches for TestResults.xml under ProjectPath.
Type: String
Parameter Sets: Path
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TruePath to the project directory used to locate test results when Path is not specified.
Type: String
Parameter Sets: Path, TestResults
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TrueInclude successful tests in the output (only applies to Summary format).
Type: SwitchParameter
Parameter Sets: Path, TestResults
Aliases: None
Possible values:
Required: False
Position: named
Default value: None
Accept pipeline input: False
Accept wildcard characters: TruePester test results object from Invoke-Pester, a ModuleTestSuiteResult from Invoke-ModuleTestSuite, or a precomputed ModuleTestFailureAnalysis.
Type: Object
Parameter Sets: TestResults
Aliases: None
Possible values:
Required: True
Position: named
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: TrueThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
System.Object
System.Object
- None