From d201d7f4a6e6058c272fe75bb832dc78a418272f Mon Sep 17 00:00:00 2001 From: Fred Hebert Date: Fri, 18 Dec 2015 22:04:44 -0500 Subject: A bad template index does not crash; shows warning This should fix #955 The test is implicit as a bad index previously silently crashed rebar3. By adding the bad index to the `new` suite's files, we can show that things keep running. --- src/rebar_prv_new.erl | 20 ++++++++++++++++---- src/rebar_templater.erl | 18 ++++++++++++------ 2 files changed, 28 insertions(+), 10 deletions(-) (limited to 'src') diff --git a/src/rebar_prv_new.erl b/src/rebar_prv_new.erl index 28572a9..71560d5 100644 --- a/src/rebar_prv_new.erl +++ b/src/rebar_prv_new.erl @@ -7,6 +7,7 @@ format_error/1]). -include("rebar.hrl"). +-include_lib("providers/include/providers.hrl"). -define(PROVIDER, new). -define(DEPS, []). @@ -35,16 +36,16 @@ do(State) -> case strip_flags(rebar_state:command_args(State)) of ["help"] -> ?CONSOLE("Call `rebar3 new help