From ba954cfb43f0b05e15ee206b13488d62c3537267 Mon Sep 17 00:00:00 2001 From: Fred Hebert <mononcqc@ferd.ca> Date: Fri, 27 Jan 2017 21:30:18 -0500 Subject: Survive EDoc crashes Instead of a hard crash, display an error message indicating which app failed. We can't report the exact failure; only EDoc does it to stdout itself and we can't capture it. Pre/Post hooks are run properly despite the failure, as per escript and compile providers. --- test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl (limited to 'test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl') diff --git a/test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl b/test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl new file mode 100644 index 0000000..2afb745 --- /dev/null +++ b/test/rebar_edoc_SUITE_data/bad/apps/bar2/src/bar2.erl @@ -0,0 +1,12 @@ +%% @doc one docline is fine +%% @doc a second docline causes a failure +%% @doc if not, then a & causes a bad ref error. +-module(bar2). +-export([bar2/0]). +-export_type([barer2/0]). + +-type barer2() :: string(). + +% @doc Bar2 bars the bar2. +-spec bar2() -> barer2(). +bar2() -> "Barer2". -- cgit v1.1