Skip to content

Commit

Permalink
Test retries with mix test --failed
Browse files Browse the repository at this point in the history
Might not work with some elixir versions (should check) and
it allows for flakyness but we're in a flaky domain.
  • Loading branch information
PragTob committed Aug 20, 2023
1 parent 7ac9489 commit b50f7d8
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,13 @@ jobs:
if: contains(matrix.elixir_version, '1.13')
run: mix format --check-formatted
- name: Actual Tests
run: MIX_ENV=test mix coveralls.github
# this will let warnings slip through but I don't wanna replicate all that magic
# right now
run: MIX_ENV=test mix coveralls.github || mix test --failed
# Apparently the one with `!` can't go without the fancy expression syntax
if: ${{ !contains(matrix.elixir_version, '1.13') }}
- name: Actual Tests WITH warnings as errors
run: MIX_ENV=test mix coveralls.github --warnings-as-errors
run: MIX_ENV=test mix coveralls.github --warnings-as-errors || mix test --failed
if: contains(matrix.elixir_version, '1.13')
- name: Dialyzer
run: mix dialyzer --halt-exit-status
Expand Down Expand Up @@ -102,7 +104,7 @@ jobs:
- run: mix deps.get
- run: mix local.rebar --force
- run: MIX_ENV=test mix compile --warnings-as-errors
- run: mix test
- run: mix test || mix test --failed

windows:
name: Test on Windows
Expand Down Expand Up @@ -131,4 +133,4 @@ jobs:
mix local.rebar --force
mix compile --warnings-as-errors
- name: Test
run: mix test
run: mix test || mix test --failed

0 comments on commit b50f7d8

Please sign in to comment.