< Back
Test-PSBuildPester
Post
NAME Test-PSBuildPester
SYNOPSIS
Execute Pester tests for module.
SYNTAX
Test-PSBuildPester [-Path] <String> [[-ModuleName] <String>] [[-OutputPath] <String>] [[-OutputFormat] <String>]
[-CodeCoverage] [[-CodeCoverageThreshold] <Double>] [[-CodeCoverageFiles] <String[]>] [<CommonParameters>]
DESCRIPTION
Execute Pester tests for module.
PARAMETERS
-Path <String>
Directory Pester tests to execute.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ModuleName <String>
Name of Module to test.
Required? false
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-OutputPath <String>
Output path to store Pester test results to.
Required? false
Position? 3
Default value
Accept pipeline input? false
Accept wildcard characters? false
-OutputFormat <String>
Test result output format (NUnit).
Required? false
Position? 4
Default value NUnitXml
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverage [<SwitchParameter>]
Switch to indicate that code coverage should be calculated.
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverageThreshold <Double>
Threshold required to pass code coverage test (.90 = 90%).
Required? false
Position? 5
Default value 0
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverageFiles <String[]>
Array of files to validate code coverage for.
Required? false
Position? 6
Default value @()
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS>Test-PSBuildPester -Path ./tests -ModuleName Mymodule -OutputPath ./out/testResults.xml
Run Pester tests in ./tests and save results to ./out/testResults.xml
RELATED LINKS
SYNOPSIS
Execute Pester tests for module.
SYNTAX
Test-PSBuildPester [-Path] <String> [[-ModuleName] <String>] [[-OutputPath] <String>] [[-OutputFormat] <String>]
[-CodeCoverage] [[-CodeCoverageThreshold] <Double>] [[-CodeCoverageFiles] <String[]>] [<CommonParameters>]
DESCRIPTION
Execute Pester tests for module.
PARAMETERS
-Path <String>
Directory Pester tests to execute.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ModuleName <String>
Name of Module to test.
Required? false
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-OutputPath <String>
Output path to store Pester test results to.
Required? false
Position? 3
Default value
Accept pipeline input? false
Accept wildcard characters? false
-OutputFormat <String>
Test result output format (NUnit).
Required? false
Position? 4
Default value NUnitXml
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverage [<SwitchParameter>]
Switch to indicate that code coverage should be calculated.
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverageThreshold <Double>
Threshold required to pass code coverage test (.90 = 90%).
Required? false
Position? 5
Default value 0
Accept pipeline input? false
Accept wildcard characters? false
-CodeCoverageFiles <String[]>
Array of files to validate code coverage for.
Required? false
Position? 6
Default value @()
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS>Test-PSBuildPester -Path ./tests -ModuleName Mymodule -OutputPath ./out/testResults.xml
Run Pester tests in ./tests and save results to ./out/testResults.xml
RELATED LINKS