diff --git a/templates/PSFTests/general/Help.Tests.ps1 b/templates/PSFTests/general/Help.Tests.ps1 index f34879a..be1c012 100644 --- a/templates/PSFTests/general/Help.Tests.ps1 +++ b/templates/PSFTests/general/Help.Tests.ps1 @@ -48,7 +48,9 @@ if ($SkipTest) { return } . $ExceptionsFile $includedNames = (Get-ChildItem $CommandPath -Recurse -File | Where-Object Name -like "*.ps1").BaseName -$commands = Get-Command -Module (Get-Module $ModuleName) -CommandType Cmdlet, Function, Workflow | Where-Object Name -in $includedNames +$commandTypes = @('Cmdlet', 'Function') +if ($PSVersionTable.PSEdition -eq 'Desktop' ) { $commandTypes += 'Workflow' } +$commands = Get-Command -Module (Get-Module $ModuleName) -CommandType $commandTypes | Where-Object Name -In $includedNames ## When testing help, remember that help is cached at the beginning of each session. ## To test, restart session.