aboutsummaryrefslogtreecommitdiffstats
path: root/lib/eunit/include/eunit.hrl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/eunit/include/eunit.hrl')
-rw-r--r--lib/eunit/include/eunit.hrl10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/eunit/include/eunit.hrl b/lib/eunit/include/eunit.hrl
index 8f678b0290..7fd6c206a4 100644
--- a/lib/eunit/include/eunit.hrl
+++ b/lib/eunit/include/eunit.hrl
@@ -212,6 +212,7 @@
-define(debugHere, ok).
-define(debugFmt(S, As), ok).
-define(debugVal(E), (E)).
+-define(debugValAll(E), (E)).
-define(debugTime(S, E), (E)).
-else.
-define(debugMsg(S),
@@ -222,13 +223,18 @@
end).
-define(debugHere, (?debugMsg("<-"))).
-define(debugFmt(S, As), (?debugMsg(io_lib:format((S), (As))))).
--define(debugVal(E),
+-define(debugVal(E, D),
begin
((fun (__V) ->
- ?debugFmt(<<"~ts = ~tP">>, [(??E), __V, 15]),
+ ?debugFmt(<<"~ts = ~tP">>,
+ [(??E), __V, D]),
__V
end)(E))
end).
+-ifndef(EUNIT_DEBUG_VAL_DEPTH).
+-define(EUNIT_DEBUG_VAL_DEPTH, 15).
+-endif.
+-define(debugVal(E), ?debugVal(E, ?EUNIT_DEBUG_VAL_DEPTH)).
-define(debugTime(S, E),
begin
((fun () ->