summaryrefslogtreecommitdiff
path: root/test/src
diff options
context:
space:
mode:
authorAyanda Dube <ayanda.dube@erlang-solutions.com>2015-10-07 16:51:54 +0100
committerAyanda Dube <ayanda.dube@erlang-solutions.com>2015-10-07 16:51:54 +0100
commitb209bf307000864e6370a1c37c7c73f4a17045f9 (patch)
treefb001d73249a8eae21368b2aafdb35f82d7ed702 /test/src
parent6f3a691bfcea075d37e1d9702e2e854a2c5e4c01 (diff)
downloadrabbitmq-server-git-b209bf307000864e6370a1c37c7c73f4a17045f9.tar.gz
Changes socket to passive.
Adds verification of AMQP connection - checks if AMQP method is replied back, with no open channels. Replaces timer:sleep(100) by setting timeout in gen_tcp:recv/3. References #62
Diffstat (limited to 'test/src')
-rw-r--r--test/src/timeout_tests.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/src/timeout_tests.erl b/test/src/timeout_tests.erl
index 7ba6e80500..800911b353 100644
--- a/test/src/timeout_tests.erl
+++ b/test/src/timeout_tests.erl
@@ -92,9 +92,9 @@ test_list_operations_timeout_pass() ->
%% list connections
{H, P} = find_listener(),
- {ok, C} = gen_tcp:connect(H, P, []),
+ {ok, C} = gen_tcp:connect(H, P, [binary, {active, false}]),
gen_tcp:send(C, <<"AMQP", 0, 0, 9, 1>>),
- timer:sleep(100),
+ {ok, <<1,0,0>>} = gen_tcp:recv(C, 3, 100),
ok = info_action(list_connections,
rabbit_networking:connection_info_keys(),
false,