summaryrefslogtreecommitdiff
path: root/src/rebar_eunit.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/rebar_eunit.erl')
-rw-r--r--src/rebar_eunit.erl35
1 files changed, 1 insertions, 34 deletions
diff --git a/src/rebar_eunit.erl b/src/rebar_eunit.erl
index 439b8f9..2b887ee 100644
--- a/src/rebar_eunit.erl
+++ b/src/rebar_eunit.erl
@@ -63,40 +63,7 @@
%% Public API
%% ===================================================================
-eunit(Config, AppFile) ->
- %% Check for app global parameter; this is a comma-delimited list
- %% of apps on which we want to run eunit
- case rebar_config:get_global(app, undefined) of
- undefined ->
- %% No app parameter specified, check the skip list..
- case rebar_config:get_global(skip_app, undefined) of
- undefined ->
- %% no skip list, run everything..
- ok;
- SkipApps ->
- TargetApps = [list_to_atom(A) ||
- A <- string:tokens(SkipApps, ",")],
- ThisApp = rebar_app_utils:app_name(AppFile),
- case lists:member(ThisApp, TargetApps) of
- false ->
- ok;
- true ->
- ?DEBUG("Skipping eunit on app: ~p\n", [ThisApp]),
- throw(ok)
- end
- end;
- Apps ->
- TargetApps = [list_to_atom(A) || A <- string:tokens(Apps, ",")],
- ThisApp = rebar_app_utils:app_name(AppFile),
- case lists:member(ThisApp, TargetApps) of
- true ->
- ok;
- false ->
- ?DEBUG("Skipping eunit on app: ~p\n", [ThisApp]),
- throw(ok)
- end
- end,
-
+eunit(Config, _AppFile) ->
%% Make sure ?EUNIT_DIR/ and ebin/ directory exists (tack on dummy module)
ok = filelib:ensure_dir(eunit_dir() ++ "/foo"),
ok = filelib:ensure_dir(ebin_dir() ++ "/foo"),