Skip to content

Commit 159a394

Browse files
author
Kapil Borle
committed
Set the severity level of AvoidUsingConvertToSecureStringWithPlainText
1 parent 9ce81fe commit 159a394

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Rules/AvoidUsingConvertToSecureStringWithPlainText.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ public override SourceType GetSourceType()
113113
/// <returns></returns>
114114
public override RuleSeverity GetSeverity()
115115
{
116-
return RuleSeverity.Warning;
116+
return RuleSeverity.Error;
117117
}
118118

119119
/// <summary>
@@ -122,7 +122,7 @@ public override RuleSeverity GetSeverity()
122122
/// <returns></returns>
123123
public override DiagnosticSeverity GetDiagnosticSeverity()
124124
{
125-
return DiagnosticSeverity.Warning;
125+
return DiagnosticSeverity.Error;
126126
}
127127

128128
/// <summary>

Tests/Engine/GetScriptAnalyzerRule.tests.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,17 +126,17 @@ Describe "Test RuleExtension" {
126126
Describe "TestSeverity" {
127127
It "filters rules based on the specified rule severity" {
128128
$rules = Get-ScriptAnalyzerRule -Severity Error
129-
$rules.Count | Should be 5
129+
$rules.Count | Should be 6
130130
}
131131

132132
It "filters rules based on multiple severity inputs"{
133133
$rules = Get-ScriptAnalyzerRule -Severity Error,Information
134-
$rules.Count | Should be 12
134+
$rules.Count | Should be 13
135135
}
136136

137137
It "takes lower case inputs" {
138138
$rules = Get-ScriptAnalyzerRule -Severity error
139-
$rules.Count | Should be 5
139+
$rules.Count | Should be 6
140140
}
141141
}
142142

0 commit comments

Comments
 (0)