Skip to content

Commit b457755

Browse files
committed
Fix other tests that failed as a result of adding a new default rule
1 parent aeead84 commit b457755

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

Tests/Engine/GetScriptAnalyzerRule.tests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ Describe "Test Name parameters" {
6161

6262
It "get Rules with no parameters supplied" {
6363
$defaultRules = Get-ScriptAnalyzerRule
64-
$expectedNumRules = 51
64+
$expectedNumRules = 52
6565
if ((Test-PSEditionCoreClr) -or (Test-PSVersionV3) -or (Test-PSVersionV4))
6666
{
6767
# for PSv3 PSAvoidGlobalAliases is not shipped because
@@ -159,7 +159,7 @@ Describe "TestSeverity" {
159159

160160
It "filters rules based on multiple severity inputs"{
161161
$rules = Get-ScriptAnalyzerRule -Severity Error,Information
162-
$rules.Count | Should be 13
162+
$rules.Count | Should be 14
163163
}
164164

165165
It "takes lower case inputs" {

Tests/Rules/BadCmdlet.ps1

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
function Verb-Files
22
{
3-
[CmdletBinding(DefaultParameterSetName='Parameter Set 1',
4-
SupportsShouldProcess=$true,
3+
[CmdletBinding(DefaultParameterSetName='Parameter Set 1',
4+
SupportsShouldProcess=$true,
55
PositionalBinding=$false,
66
HelpUri = 'http://www.microsoft.com/',
77
ConfirmImpact='Medium')]
@@ -12,17 +12,17 @@
1212
Param
1313
(
1414
# Param1 help description
15-
[Parameter(Mandatory=$true,
15+
[Parameter(Mandatory=$true,
1616
ValueFromPipeline=$true,
17-
ValueFromPipelineByPropertyName=$true,
18-
ValueFromRemainingArguments=$false,
17+
ValueFromPipelineByPropertyName=$true,
18+
ValueFromRemainingArguments=$false,
1919
Position=0,
2020
ParameterSetName='Parameter Set 1')]
2121
[ValidateNotNull()]
2222
[ValidateNotNullOrEmpty()]
2323
[ValidateCount(0,5)]
2424
[ValidateSet("sun", "moon", "earth")]
25-
[Alias("p1")]
25+
[Alias("p1")]
2626
$Param1,
2727

2828
# Param2 help description

0 commit comments

Comments
 (0)