aboutsummaryrefslogtreecommitdiffstats
path: root/test/rlx_discover_SUITE.erl
diff options
context:
space:
mode:
authorTristan Sloughter <[email protected]>2013-09-28 11:56:32 -0500
committerTristan Sloughter <[email protected]>2013-09-28 16:26:00 -0500
commit3fc8e0408cd27e15fdfbd3711c6ab18140745c86 (patch)
treef18af1a207aa2964e49085081a6dcc4f06c2ac10 /test/rlx_discover_SUITE.erl
parent8a60327694646893729cde1708be4f507beceae0 (diff)
downloadrelx-3fc8e0408cd27e15fdfbd3711c6ab18140745c86.tar.gz
relx-3fc8e0408cd27e15fdfbd3711c6ab18140745c86.tar.bz2
relx-3fc8e0408cd27e15fdfbd3711c6ab18140745c86.zip
warn, not error, on bad app during discovery provider
Diffstat (limited to 'test/rlx_discover_SUITE.erl')
-rw-r--r--test/rlx_discover_SUITE.erl9
1 files changed, 4 insertions, 5 deletions
diff --git a/test/rlx_discover_SUITE.erl b/test/rlx_discover_SUITE.erl
index 93a576b..e75ea36 100644
--- a/test/rlx_discover_SUITE.erl
+++ b/test/rlx_discover_SUITE.erl
@@ -138,12 +138,11 @@ bad_ebin_case(Config) ->
Filename = filename:join([AppDir, <<"ebin">>, BadName ++ ".app"]),
ok = filelib:ensure_dir(Filename),
ok = ec_file:write_term(Filename, get_bad_app_metadata(BadName, BadVsn)),
- write_beam_file(AppDir, BadName),
State0 = proplists:get_value(state, Config),
{DiscoverProvider, {ok, State1}} = rlx_provider:new(rlx_prv_discover, State0),
- ?assertMatch({error, {_, [{invalid_app_file, Filename}]}},
- rlx_provider:do(DiscoverProvider, State1)).
-
+ {ok, State2} = rlx_provider:do(DiscoverProvider, State1),
+ ?assertMatch([], [App || App <- rlx_state:available_apps(State2),
+ BadName =:= rlx_app_info:name(App)]).
%%%===================================================================
%%% Helper functions
@@ -178,7 +177,7 @@ get_bad_app_metadata(Name, Vsn) ->
["{application, ", Name, ",
[{description, \"\"},
{vsn, \"", Vsn, "\"},
- {modules, [],
+ {modules, [missing],
{applications, [kernel, stdlib]}]}."].