aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/src/ct_hooks.erl
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2017-05-31 19:13:36 +0200
committerSiri Hansen <[email protected]>2017-06-16 11:52:20 +0200
commit9d95abb3597eb4e19df40704fe8533b5d384d3e9 (patch)
tree69ac5ce1be04f70fedb84431362d576b1a61b484 /lib/common_test/src/ct_hooks.erl
parentd3a53ae2b2800b33f3b25b83ff2314e64153c2aa (diff)
downloadotp-9d95abb3597eb4e19df40704fe8533b5d384d3e9.tar.gz
otp-9d95abb3597eb4e19df40704fe8533b5d384d3e9.tar.bz2
otp-9d95abb3597eb4e19df40704fe8533b5d384d3e9.zip
[ct] Print unicode atoms and strings correctly in common_test logs
And use correct encoding when printing to files.
Diffstat (limited to 'lib/common_test/src/ct_hooks.erl')
-rw-r--r--lib/common_test/src/ct_hooks.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/common_test/src/ct_hooks.erl b/lib/common_test/src/ct_hooks.erl
index 8cdc6d8c75..f0592a40be 100644
--- a/lib/common_test/src/ct_hooks.erl
+++ b/lib/common_test/src/ct_hooks.erl
@@ -235,7 +235,7 @@ call([{Hook, call_id, NextFun} | Rest], Config, Meta, Hooks) ->
call(resort(NewRest,NewHooks,Meta), Config, Meta, NewHooks)
catch Error:Reason ->
Trace = erlang:get_stacktrace(),
- ct_logs:log("Suite Hook","Failed to start a CTH: ~p:~p",
+ ct_logs:log("Suite Hook","Failed to start a CTH: ~tp:~tp",
[Error,{Reason,Trace}]),
call([], {fail,"Failed to start CTH"
", see the CT Log for details"}, Meta, Hooks)
@@ -424,11 +424,11 @@ catch_apply(M,F,A) ->
erlang:apply(M,F,A)
catch _:Reason ->
Trace = erlang:get_stacktrace(),
- ct_logs:log("Suite Hook","Call to CTH failed: ~w:~p",
+ ct_logs:log("Suite Hook","Call to CTH failed: ~w:~tp",
[error,{Reason,Trace}]),
throw({error_in_cth_call,
lists:flatten(
- io_lib:format("~w:~w/~w CTH call failed",
+ io_lib:format("~w:~tw/~w CTH call failed",
[M,F,length(A)]))})
end.