Skip to content

Commit 13846bd

Browse files
authored
Fail when misnamed test files are detected and --warnings-as-errors is set (#15106)
Closes #15105.
1 parent b05fec0 commit 13846bd

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

lib/mix/lib/mix/tasks/test.ex

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,8 @@ defmodule Mix.Tasks.Test do
714714
cover && cover.()
715715

716716
cond do
717-
warnings_as_errors? and (warnings? or helper_warned?) and failures == 0 ->
717+
warnings_as_errors? and (warnings? or helper_warned? or warn_files != []) and
718+
failures == 0 ->
718719
message =
719720
"\nERROR! Test suite aborted after successful execution due to warnings while using the --warnings-as-errors option"
720721

0 commit comments

Comments
 (0)