From 9b67b6a5116ecc3ce9d8385e951f6c19252b2935 Mon Sep 17 00:00:00 2001 From: Ted Ross Date: Tue, 20 Jan 2009 20:33:04 +0000 Subject: QPID-1601 Ruby test patch from Justin Ross git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@736094 13f79535-47bb-0310-9956-ffa450edef68 --- ruby/tests/qmf.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ruby/tests/qmf.rb b/ruby/tests/qmf.rb index 8bd9218366..b0ee19c3d5 100644 --- a/ruby/tests/qmf.rb +++ b/ruby/tests/qmf.rb @@ -28,8 +28,10 @@ class QmfTest < Test::Unit::TestCase # Make sure errors in threads lead to a noisy death of the test Thread.abort_on_exception = true - sock = TCPSocket.new(ENV.fetch("QMF_TEST_HOST", 'localhost'), - ENV.fetch("QMF_TEST_PORT", 5672)) + host = ENV.fetch("QMF_TEST_HOST", 'localhost') + port = ENV.fetch("QMF_TEST_PORT", 5672) + + sock = TCPSocket.new(host, port) @conn = Qpid::Connection.new(sock) @conn.start() @@ -39,7 +41,7 @@ class QmfTest < Test::Unit::TestCase # It's a bit odd that we're using two connections but that's the way # the python one works afaict. @qmf = Qpid::Qmf::Session.new() - @qmf_broker = @qmf.add_broker("amqp://localhost:5672") + @qmf_broker = @qmf.add_broker("amqp://%s:%d" % [host, port]) brokers = @qmf.objects(:class => "broker") assert_equal(1, brokers.length) -- cgit v1.2.1