From 2794f452c8197a9c242c7e3652481f4f4d6e3422 Mon Sep 17 00:00:00 2001 From: Siri Hansen Date: Tue, 16 Oct 2012 18:28:30 +0200 Subject: [test_server] Multiply timers with timetrap_scale_factor when starting nodes In test_server_ctrl:start_node and wait_for_node, the timer in controller_call was not multiplied by the timetrap_scale_factor. This caused unexpected behaviour since the scale factor was used furhter down the the code, and timeout would happen in unexpected order when cover was running. --- lib/test_server/src/test_server_ctrl.erl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/test_server/src/test_server_ctrl.erl b/lib/test_server/src/test_server_ctrl.erl index 7f04e2eb23..e0f66ddb54 100644 --- a/lib/test_server/src/test_server_ctrl.erl +++ b/lib/test_server/src/test_server_ctrl.erl @@ -5119,7 +5119,7 @@ get_target_info() -> %% Called by test_server. See test_server:start_node/3 for details start_node(Name, Type, Options) -> - T = 10 * ?ACCEPT_TIMEOUT, % give some extra time + T = 10 * ?ACCEPT_TIMEOUT * test_server:timetrap_scale_factor(), format(minor, "Attempt to start ~w node ~p with options ~p", [Type, Name, Options]), case controller_call({start_node,Name,Type,Options}, T) of @@ -5164,7 +5164,8 @@ start_node(Name, Type, Options) -> %% when the new node has contacted test_server_ctrl again wait_for_node(Slave) -> - case catch controller_call({wait_for_node,Slave},10000) of + T = 10000 * test_server:timetrap_scale_factor(), + case catch controller_call({wait_for_node,Slave},T) of {'EXIT',{timeout,_}} -> {error,timeout}; ok -> ok end. -- cgit v1.2.3