diff --git a/SC2314.md b/SC2314.md index d1837e4..69b2cfa 100644 --- a/SC2314.md +++ b/SC2314.md @@ -1,4 +1,4 @@ -## bats: ! \ will never fail the test +## In bats, ! does not cause a test failure ### Problematic code: @@ -39,8 +39,6 @@ The return code of the last command in the test will be the exit code of the tes This means that you can use `! ` on the last line of the test and it will still fail appropriately. However, you are encouraged to still use `run !` in this case for consistency. -Shellcheck won't emit this error when using `! ` as last command in a test to avoid confusing users whose tests work as intended. - ### Related resources: * [SC2251: This ! is not on a condition and skips errexit](SC2251.md)