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
{{ message }}
Repository navigation
Invoke-Formatter has knock on effect on subsequent call to Invoke-ScriptAnalyzer #1116
Using the latest state of the development branch (but also applies to RTM version of 1.17.1 and 1.16.1, therefore the bug has been present even before I joined the project).
I believe this bug is the main culprit of PSSA's tests sometimes becoming flaky and starting to fail sometimes when the test order changes.
cc James Truher (@JamesWTruher)
Describe "PSSA bug" {
It "Invoke-ScriptAnalyzer works fine" {
Invoke-ScriptAnalyzer-ScriptDefinition 'gci'| Should -Not-BeNullOrEmpty
}
It "Invoke-Formatter has knock on effect on Invoke-ScriptAnalyzer" {
Invoke-Formatter'foo'Invoke-ScriptAnalyzer-ScriptDefinition 'gci'| Should -Not-BeNullOrEmpty
}
It "Invoke-Formatter has knock on effect on Invoke-ScriptAnalyzer but it works the 2nd time" {
Invoke-Formatter'foo'Invoke-ScriptAnalyzer-ScriptDefinition 'gci'Invoke-ScriptAnalyzer-ScriptDefinition 'gci'| Should -Not-BeNullOrEmpty
}
}
The 2nd test will fail, which is exposing the problem
changed the title [-]Invoke-Formatter has knock on effect on susequent call to Invoke-ScriptAnalyzer[/-][+]Invoke-Formatter has knock on effect on subsequent call to Invoke-ScriptAnalyzer[/+]on Dec 27, 2018
Activity
[-]Invoke-Formatter has knock on effect on susequent call to Invoke-ScriptAnalyzer[/-][+]Invoke-Formatter has knock on effect on subsequent call to Invoke-ScriptAnalyzer[/+]