You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$nonInitializedMessage="Variable 'a' is not initialized. Non-global variables must be initialized. To fix a violation of this rule, please initialize non-global variables."
5
+
$nonInitializedMessage="Variable 'globalVars' is not initialized. Non-global variables must be initialized. To fix a violation of this rule, please initialize non-global variables."
Copy file name to clipboardExpand all lines: Tests/Rules/AvoidPositionalParameters.tests.ps1
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
Import-Module PSScriptAnalyzer
2
-
$violationMessage="Cmdlet 'Get-Content' has positional parameter. Please use named parameters instead of positional parameters when calling a command."
2
+
$violationMessage="Cmdlet 'Write-Host' has positional parameter. Please use named parameters instead of positional parameters when calling a command."
Copy file name to clipboardExpand all lines: Tests/Rules/AvoidShouldContinueWithoutForce.tests.ps1
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
Import-Module PSScriptAnalyzer
2
-
$violationMessage="Function 'Verb-Noun' in file 'AvoidShouldContinueWithoutForce.ps1' uses ShouldContinue but does not have a boolean force parameter. The force parameter will allow users of the script to bypass ShouldContinue prompt"
2
+
$violationMessage="Function 'Verb-Noun2' in file 'AvoidShouldContinueWithoutForce.ps1' uses ShouldContinue but does not have a boolean force parameter. The force parameter will allow users of the script to bypass ShouldContinue prompt"
Copy file name to clipboardExpand all lines: Tests/Rules/AvoidUsingAlias.tests.ps1
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
Import-Module PSScriptAnalyzer
2
-
$violationMessage="'iex' is an alias of 'Invoke-Expression'. Alias can introduce possible problems and make scripts hard to maintain. Please consider changing alias to its full content."
2
+
$violationMessage="'cls' is an alias of 'Clear-Host'. Alias can introduce possible problems and make scripts hard to maintain. Please consider changing alias to its full content."
Copy file name to clipboardExpand all lines: Tests/Rules/AvoidUsingPlainTextForPassword.tests.ps1
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
Import-Module PSScriptAnalyzer
2
2
3
-
$violationMessage= [regex]::Escape("Parameter '`$passphrases' should use SecureString, otherwise this will expose sensitive information. See ConvertTo-SecureString for more information.")
3
+
$violationMessage= [regex]::Escape("Parameter '`$password' should use SecureString, otherwise this will expose sensitive information. See ConvertTo-SecureString for more information.")
$violationMessage="Variable 'MyProgressPreference' is not initialized. Non-global variables must be initialized. To fix a violation of this rule, please initialize non-global variables."
3
+
$violationMessage="Variable 'MyVerbosePreference' is not initialized. Non-global variables must be initialized. To fix a violation of this rule, please initialize non-global variables."
0 commit comments