aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_server/src/test_server_ctrl.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2012-09-19 15:19:59 +0200
committerDan Gudmundsson <[email protected]>2012-09-19 15:19:59 +0200
commit8d78a10998ae7d87dfef4427a1be922aba46859a (patch)
tree13e5ed956164b76397ed1e0769d565c9dcc8d3f2 /lib/test_server/src/test_server_ctrl.erl
parentb58ce62a0cf296ca8cd8cd77b053bc70ecf28758 (diff)
downloadotp-8d78a10998ae7d87dfef4427a1be922aba46859a.tar.gz
otp-8d78a10998ae7d87dfef4427a1be922aba46859a.tar.bz2
otp-8d78a10998ae7d87dfef4427a1be922aba46859a.zip
[ct] Block output into single io call
Add newlines to the same io function call, so that concurrent io always starts at a new line.
Diffstat (limited to 'lib/test_server/src/test_server_ctrl.erl')
-rw-r--r--lib/test_server/src/test_server_ctrl.erl15
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/test_server/src/test_server_ctrl.erl b/lib/test_server/src/test_server_ctrl.erl
index a38e2be98e..bc4c7d2bb5 100644
--- a/lib/test_server/src/test_server_ctrl.erl
+++ b/lib/test_server/src/test_server_ctrl.erl
@@ -4679,21 +4679,16 @@ output_to_fd(stdout, Msg, Sender) ->
io:format("Testing ~s: ~s\n", [Name, lists:flatten(Msg)]);
output_to_fd(undefined, _Msg, _Sender) ->
ok;
-output_to_fd(Fd, [$=|Msg], internal) ->
- io:put_chars(Fd, [$=]),
- io:put_chars(Fd, Msg),
- io:put_chars(Fd, "\n");
+output_to_fd(Fd, Msg=[$=|_], internal) ->
+ io:put_chars(Fd, [Msg,"\n"]);
output_to_fd(Fd, Msg, internal) ->
- io:put_chars(Fd, [$=,$=,$=,$ ]),
- io:put_chars(Fd, Msg),
- io:put_chars(Fd, "\n");
+ io:put_chars(Fd, [$=,$=,$=,$ , Msg, "\n"]);
output_to_fd(Fd, Msg, _Sender) ->
- io:put_chars(Fd, Msg),
case get(test_server_log_nl) of
- false -> ok;
- _ -> io:put_chars(Fd, "\n")
+ false -> io:put_chars(Fd, Msg);
+ _ -> io:put_chars(Fd, [Msg,"\n"])
end.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%