File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change 99 Path :
1010 description : The path to the code to test.
1111 required : false
12- default : ' .'
1312 Settings :
1413 description : The type of tests to run. Can be either 'Module', 'SourceCode' or 'Custom'.
1514 required : false
Original file line number Diff line number Diff line change 11# If test type is module, the code we ought to test is in the path/name folder, otherwise it's in the path folder.
22$settings = $env: PSMODULE_INVOKE_SCRIPTANALYZER_INPUT_Settings
33$testPath = Resolve-Path - Path " $PSScriptRoot /tests/PSScriptAnalyzer" | Select-Object - ExpandProperty Path
4- $codePath = Resolve-Path - Path $env: PSMODULE_INVOKE_SCRIPTANALYZER_INPUT_Path | Select-Object - ExpandProperty Path
4+ $path = [string ]::IsNullOrEmpty($env: PSMODULE_INVOKE_SCRIPTANALYZER_INPUT_Path ) ? ' .' : $env: PSMODULE_INVOKE_SCRIPTANALYZER_INPUT_Path
5+ $codePath = Resolve-Path - Path $path | Select-Object - ExpandProperty Path | Select-Object - ExpandProperty Path
56$settingsFilePath = switch - Regex ($settings ) {
67 ' Module|SourceCode' {
78 " $testPath /$settings .Settings.psd1"
You can’t perform that action at this time.
0 commit comments