aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_server
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2012-10-31 16:24:43 +0100
committerBjörn Gustavsson <[email protected]>2012-11-07 14:14:00 +0100
commit926dbcfbb4683f4c217504c590e36cb76f06dced (patch)
treea44dba0eff49d0a8f9737f2ef68540b9294640c7 /lib/test_server
parentc1cfd8368b68e9caa91cb2da889d83d65277ac53 (diff)
downloadotp-926dbcfbb4683f4c217504c590e36cb76f06dced.tar.gz
otp-926dbcfbb4683f4c217504c590e36cb76f06dced.tar.bz2
otp-926dbcfbb4683f4c217504c590e36cb76f06dced.zip
Make sure that "Testing..." is not written if testing has finished
When writing messages to stdout, all messages are prefixed with "Testing" followed by the name of the test suite. We don't want to write that prefix if testing has stopped.
Diffstat (limited to 'lib/test_server')
-rw-r--r--lib/test_server/src/test_server_ctrl.erl1
-rw-r--r--lib/test_server/src/test_server_io.erl2
2 files changed, 3 insertions, 0 deletions
diff --git a/lib/test_server/src/test_server_ctrl.erl b/lib/test_server/src/test_server_ctrl.erl
index 4e465c02d1..6ea69b5e58 100644
--- a/lib/test_server/src/test_server_ctrl.erl
+++ b/lib/test_server/src/test_server_ctrl.erl
@@ -1416,6 +1416,7 @@ init_tester(Mod, Func, Args, Dir, Name, {_,_,MinLev}=Levels,
group_leader(test_server_io:get_gl(true), self()),
{TimeMy,Result} = ts_tc(Mod, Func, Args),
set_io_buffering(undefined),
+ test_server_io:set_job_name(undefined),
catch stop_extra_tools(StartedExtraTools),
case Result of
{'EXIT',test_suites_done} ->
diff --git a/lib/test_server/src/test_server_io.erl b/lib/test_server/src/test_server_io.erl
index abdfb71241..7ec36d0c1f 100644
--- a/lib/test_server/src/test_server_io.erl
+++ b/lib/test_server/src/test_server_io.erl
@@ -253,6 +253,8 @@ output(From, Tag, Str, #st{io_buffering=Buffered,buffered=Buf0}=St) ->
St#st{buffered=Buf}
end.
+do_output(stdout, Str, #st{job_name=undefined}) ->
+ io:put_chars(Str);
do_output(stdout, Str0, #st{job_name=Name}) ->
Str = io_lib:format("Testing ~s: ~s\n", [Name,Str0]),
io:put_chars(Str);