Skip to content

Commit

Permalink
Merge pull request #14 from juanedi/master
Browse files Browse the repository at this point in the history
Abort exunit if a suite fails.
  • Loading branch information
josevalim committed Apr 20, 2015
2 parents 9db87db + c953a47 commit 7058379
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/rebar_exunit.erl
Expand Up @@ -78,4 +78,8 @@ perform_exunit(_Config, Files) ->
_ -> ok
end,
[ 'Elixir.Code':require_file(list_to_binary(File)) || File <- Files ],
'Elixir.ExUnit':run().
Result = 'Elixir.ExUnit':run(),
case maps:get(failures, Result) of
0 -> ok;
F -> rebar_utils:abort("~p tests failed.~n", [F])
end.

0 comments on commit 7058379

Please sign in to comment.