Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove Unnecessary ExcludeRule
  • Loading branch information
PoshAJ authored and poshAJ committed Feb 24, 2025
commit 2360fb50b14645bad3b0dd7848e255da5d0c10fb
2 changes: 1 addition & 1 deletion Tests/Rules/AvoidAssignmentToAutomaticVariable.tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ Describe "AvoidAssignmentToAutomaticVariables" {
It "Using Variable <VariableName> as foreach name produces warning of Severity <ExpectedSeverity>" -TestCases $testCases_AutomaticVariables {
param ($VariableName, $ExpectedSeverity)

[System.Array] $warnings = Invoke-ScriptAnalyzer -ScriptDefinition "foreach (`$$VariableName in `$foo) {}" -ExcludeRule PSReviewUnusedParameter
[System.Array] $warnings = Invoke-ScriptAnalyzer -ScriptDefinition "foreach (`$$VariableName in `$foo) {}"
$warnings.Count | Should -Be 1
$warnings.Severity | Should -Be $ExpectedSeverity
$warnings.RuleName | Should -Be $ruleName
Expand Down