summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralisdair sullivan <alisdair.sullivan@askuity.com>2015-11-02 07:06:06 -0800
committeralisdair sullivan <alisdair.sullivan@askuity.com>2015-11-02 07:06:06 -0800
commit80f5bc61526f50e2fe3d4642faea6abff43cbd96 (patch)
tree17b9c7aab72d28543c98b7a701abe1ac5548b8a4
parentcf66dfd6ba65bc6f2926ce3b6b67f195a3faa715 (diff)
add warning about `auto_compile`
-rw-r--r--src/rebar_prv_common_test.erl13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/rebar_prv_common_test.erl b/src/rebar_prv_common_test.erl
index 7af2819..7a088e5 100644
--- a/src/rebar_prv_common_test.erl
+++ b/src/rebar_prv_common_test.erl
@@ -74,12 +74,13 @@ do(State, Tests) ->
run_tests(State, Opts) ->
T = translate_paths(State, Opts),
Opts1 = setup_logdir(State, T),
- ?DEBUG("ct_opts ~p", [Opts1]),
+ Opts2 = turn_off_auto_compile(Opts1),
+ ?DEBUG("ct_opts ~p", [Opts2]),
{RawOpts, _} = rebar_state:command_parsed_args(State),
ok = maybe_write_coverdata(State),
case proplists:get_value(verbose, RawOpts, false) of
- true -> run_test_verbose(Opts1);
- false -> run_test_quiet(Opts1)
+ true -> run_test_verbose(Opts2);
+ false -> run_test_quiet(Opts2)
end.
-spec format_error(any()) -> iolist().
@@ -155,6 +156,9 @@ cfgopts(State) ->
filter_opts({test_spec, _}) ->
?WARN("Test specs not supported", []),
false;
+filter_opts({auto_compile, _}) ->
+ ?WARN("Auto compile not supported", []),
+ false;
filter_opts({suite, Suite}) when is_integer(hd(Suite)) -> true;
filter_opts({suite, Suite}) when is_atom(Suite) ->
{true, {suite, atom_to_list(Suite)}};
@@ -373,6 +377,9 @@ setup_logdir(State, Opts) ->
filelib:ensure_dir(filename:join([Logdir, "dummy.beam"])),
[{logdir, Logdir}|lists:keydelete(logdir, 1, Opts)].
+turn_off_auto_compile(Opts) ->
+ [{auto_compile, false}|lists:keydelete(auto_compile, 1, Opts)].
+
run_test_verbose(Opts) -> handle_results(ct:run_test(Opts)).
run_test_quiet(Opts) ->