Skip to content

Commit fe374ec

Browse files
author
Brett Hazen
committed
Fix clique table for atoms as failure reasons
1 parent 1428fca commit fe374ec

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

src/rt_reporter.erl

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -288,12 +288,15 @@ test_summary_fun(Result = {_, {skipped, _}, _}, {{_Pass, _Fail, Skipped}, Rows})
288288
%% @doc Format a row for clique
289289
format_test_row({TestPlan, Result, Duration}) ->
290290
TestName = rt_test_plan:get_name(TestPlan),
291-
case Result of
292-
{Status, Reason} ->
293-
[TestName, Status, lists:flatten(Reason), test_summary_format_time(Duration)];
291+
{Status, Reason} = case Result of
292+
{FailOrSkip, Failure} when is_list(Failure) ->
293+
{FailOrSkip, lists:flatten(Failure)};
294+
{FailOrSkip, Failure} ->
295+
{FailOrSkip, lists:flatten(io_lib:format("~p", [Failure]))};
294296
pass ->
295-
[TestName, "pass", "N/A", test_summary_format_time(Duration)]
296-
end.
297+
{"pass", "N/A"}
298+
end,
299+
[TestName, Status, Reason, test_summary_format_time(Duration)].
297300

298301
-spec(report_to_giddyup(term(), list()) -> list).
299302
report_to_giddyup(TestResult, Logs) ->

0 commit comments

Comments
 (0)