-
Notifications
You must be signed in to change notification settings - Fork 60
Closed
Labels
bugSomething isn't workingSomething isn't workingfeature: optionsIssues that affect optionsIssues that affect options
Milestone
Description
Description of the issue
New-PSRuleOption -OutputOutcome does not accept the argument Problem or "Fail,Error".
At the same time the documentation describes Problem
https://microsoft.github.io/PSRule/v2/concepts/PSRule/en-US/about_PSRule_Options/#outputoutcome
and this workaround works, too: New-PSRuleOption -Option @{ 'Output.Outcome' = 'Fail,Error' }
To Reproduce
Steps to reproduce the issue:
New-PSRuleOption -OutputOutcome ProblemExpected behaviour
The command returns the required option.
Error output
New-PSRuleOption: Cannot validate argument on parameter 'OutputOutcome'. The argument "Problem" does not belong to the set "None,Fail,Pass,Error,Processed,All" specified by the ValidateSet attribute. Supply an argument that is in the set and then try the command again.
Module in use and version:
- Module: PSRule
- Version: 2.9.0
Captured output from $PSVersionTable:
Name Value
---- -----
PSVersion 7.4.5
PSEdition Core
GitCommitId 7.4.5
OS Microsoft Windows 10.0.22631
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
BernieWhite
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingfeature: optionsIssues that affect optionsIssues that affect options