summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2013-01-22 13:59:47 +0000
committerMatthias Radestock <matthias@rabbitmq.com>2013-01-22 13:59:47 +0000
commitfe6889ea21da979ce76f193d996361f670d7380a (patch)
tree397ad86ab8d7c9b1b6919d4dcfc6a77bb3518a92
parentc2a37249939fbdd96d60307034461488c3fb6052 (diff)
parentf01cecf0522b7495feba23a691f30594346398ab (diff)
downloadrabbitmq-server-fe6889ea21da979ce76f193d996361f670d7380a.tar.gz
merge stable into default
-rw-r--r--src/rabbit_tests.erl18
1 files changed, 8 insertions, 10 deletions
diff --git a/src/rabbit_tests.erl b/src/rabbit_tests.erl
index 6076b4f2..b0ff5af9 100644
--- a/src/rabbit_tests.erl
+++ b/src/rabbit_tests.erl
@@ -1084,16 +1084,9 @@ test_policy_validation() ->
rabbit_runtime_parameters_test:unregister_policy_validator(),
passed.
-writer() ->
- receive
- {'$gen_call', From, flush} -> gen_server:reply(From, ok),
- writer();
- shutdown -> ok
- end.
-
test_server_status() ->
%% create a few things so there is some useful information to list
- Writer = spawn(fun writer/0),
+ Writer = spawn(fun test_writer/0),
{ok, Ch} = rabbit_channel:start_link(
1, self(), Writer, self(), "", rabbit_framing_amqp_0_9_1,
user(<<"user">>), <<"/">>, [], self(),
@@ -1168,10 +1161,15 @@ test_server_status() ->
passed.
+test_writer() -> test_writer(none).
+
test_writer(Pid) ->
receive
- shutdown -> ok;
- {send_command, Method} -> Pid ! Method, test_writer(Pid)
+ {'$gen_call', From, flush} -> gen_server:reply(From, ok),
+ test_writer(Pid);
+ {send_command, Method} -> Pid ! Method,
+ test_writer(Pid);
+ shutdown -> ok
end.
test_spawn() ->