diff options
author | Peter Andersson <[email protected]> | 2016-03-05 17:09:56 +0100 |
---|---|---|
committer | Peter Andersson <[email protected]> | 2016-03-05 17:09:56 +0100 |
commit | 13051baf9f4844d4236f221311f03135144ade88 (patch) | |
tree | 85f41717ee56841d6c7fca08362226b6a0edb501 /lib/common_test/src | |
parent | 3e720193641aa92d0082586ba64fc75cda32103c (diff) | |
download | otp-13051baf9f4844d4236f221311f03135144ade88.tar.gz otp-13051baf9f4844d4236f221311f03135144ade88.tar.bz2 otp-13051baf9f4844d4236f221311f03135144ade88.zip |
Add missing internal hook functions
Diffstat (limited to 'lib/common_test/src')
-rw-r--r-- | lib/common_test/src/ct_hooks.erl | 4 | ||||
-rw-r--r-- | lib/common_test/src/cth_log_redirect.erl | 9 |
2 files changed, 10 insertions, 3 deletions
diff --git a/lib/common_test/src/ct_hooks.erl b/lib/common_test/src/ct_hooks.erl index b604074d12..83ad33fdd8 100644 --- a/lib/common_test/src/ct_hooks.erl +++ b/lib/common_test/src/ct_hooks.erl @@ -381,10 +381,10 @@ pos(Id,[_|Rest],Num) -> catch_apply(M,F,A, Default) -> try - apply(M,F,A) + erlang:apply(M,F,A) catch _:Reason -> case erlang:get_stacktrace() of - %% Return the default if it was the CTH module which did not have the function. + %% Return the default if it was the CTH module which did not have the function. [{M,F,A,_}|_] when Reason == undef -> Default; Trace -> diff --git a/lib/common_test/src/cth_log_redirect.erl b/lib/common_test/src/cth_log_redirect.erl index e6970a2bad..a8c4a455e1 100644 --- a/lib/common_test/src/cth_log_redirect.erl +++ b/lib/common_test/src/cth_log_redirect.erl @@ -30,7 +30,8 @@ pre_init_per_suite/3, pre_end_per_suite/3, post_end_per_suite/4, pre_init_per_group/3, post_init_per_group/4, pre_end_per_group/3, post_end_per_group/4, - pre_init_per_testcase/3, post_end_per_testcase/4]). + pre_init_per_testcase/3, post_init_per_testcase/4, + pre_end_per_testcase/3, post_end_per_testcase/4]). %% Event handler Callbacks -export([init/1, @@ -89,6 +90,12 @@ pre_init_per_testcase(TC, Config, State) -> set_curr_func(TC, Config), {Config, State}. +post_init_per_testcase(_TC, _Config, Return, State) -> + {Return, State}. + +pre_end_per_testcase(_TC, Config, State) -> + {Config, State}. + post_end_per_testcase(_TC, _Config, Result, State) -> %% Make sure that the event queue is flushed %% before ending this test case. |