Skip to content

Commit e1d5300

Browse files
author
Kapil Borle
committed
Update test case name in indentation tests
1 parent 3b46642 commit e1d5300

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

Tests/Rules/UseConsistentIndentation.tests.ps1

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,15 @@ where-object {$_.Name -match 'powershell'}
124124
$violations.Count | Should Be 1
125125
}
126126

127+
It "Should not find a violation if a pipleline element is indented correctly" {
128+
$def = @'
129+
get-process |
130+
where-object {$_.Name -match 'powershell'}
131+
'@
132+
$violations = Invoke-ScriptAnalyzer -ScriptDefinition $def -Settings $settings
133+
$violations.Count | Should Be 0
134+
}
135+
127136
It "Should ignore comment in the pipleline" {
128137
$def = @'
129138
get-process |
@@ -134,14 +143,5 @@ select Name,Id |
134143
$violations = Invoke-ScriptAnalyzer -ScriptDefinition $def -Settings $settings
135144
$violations.Count | Should Be 3
136145
}
137-
138-
It "Should not find a violation on a new line that follows a pipe" {
139-
$def = @'
140-
get-process |
141-
where-object {$_.Name -match 'powershell'}
142-
'@
143-
$violations = Invoke-ScriptAnalyzer -ScriptDefinition $def -Settings $settings
144-
$violations.Count | Should Be 0
145-
}
146146
}
147147
}

0 commit comments

Comments
 (0)