jonar...@gmail.com
unread,Jul 13, 2021, 4:13:37 PM7/13/21Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to elixir-lang-core
In our CI environment, we run our tests with this command:
mix test --warnings-as-errors <files>
This is intended to fail when someone has created a warning within a test file in addition to when the tests themselves fail. We have an earlier check (MIX_ENV=test mix compile --force --warnings-as-errors) that validates that our production code is warning-free, but this does not compile nor validate test files.
A few of our tests are somewhat finnicky, and will fail sporadically (e.g. due to PostgreSQL deadlocks). So we also have retry logic in our CI environment that will re-run tests when the above command exists unsuccessfully (exit code != 0). However, no amount of re-running will fix a compilation warning! Presently, both test failures and compilation failures return exit code 1, and so we are not able to differentiate between the two and only re-run in the former case.
Would it be appropriate to change the compilation failure case to return an exit code of, say, 2?