aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test
diff options
context:
space:
mode:
Diffstat (limited to 'lib/common_test')
-rw-r--r--lib/common_test/src/ct_util.erl6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/common_test/src/ct_util.erl b/lib/common_test/src/ct_util.erl
index f393ea103d..3b6ad6f98d 100644
--- a/lib/common_test/src/ct_util.erl
+++ b/lib/common_test/src/ct_util.erl
@@ -182,7 +182,11 @@ do_start(Parent,Mode,LogDir) ->
%% Initialize ct_hooks
try ct_hooks:init(Opts) of
ok ->
- Parent ! {self(),started}
+ Parent ! {self(),started};
+ {fail,CTHReason} ->
+ ct_logs:tc_print('Suite Callback',CTHReason,[]),
+ self() ! {{stop,{self(),{user_error,CTHReason}}},
+ {Parent,make_ref()}}
catch
_:CTHReason ->
ct_logs:tc_print('Suite Callback',CTHReason,[]),