qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acon...@apache.org
Subject [1/2] qpid-proton git commit: PROTON-1457: Ruby tests fail when dependencies are missing
Date Mon, 11 Sep 2017 20:51:25 GMT
Repository: qpid-proton
Updated Branches:
  refs/heads/master 363d337b5 -> 5e1bce7a0


http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/spec/qpid/proton/hash_spec.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/spec/qpid/proton/hash_spec.rb b/proton-c/bindings/ruby/spec/qpid/proton/hash_spec.rb
deleted file mode 100644
index 7568ac1..0000000
--- a/proton-c/bindings/ruby/spec/qpid/proton/hash_spec.rb
+++ /dev/null
@@ -1,57 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-require "spec_helper"
-
-describe "The extended hash type" do
-
-  before :each do
-    @data = Qpid::Proton::Codec::Data.new
-    @hash = random_hash(rand(128) + 64)
-  end
-
-  it "raises an error when put into a nil Data instance" do
-    expect {
-      @hash.proton_data_put(nil)
-    }.to raise_error(TypeError)
-  end
-
-  it "can be put into an instance of Data" do
-    @hash.proton_data_put(@data)
-    result = Hash.proton_data_get(@data)
-    expect(result.keys).to match_array(@hash.keys)
-    expect(result.values).to match_array(@hash.values)
-  end
-
-  it "raises an error when retrieved from a nil Data instance" do
-    expect {
-      Hash.proton_data_get(nil)
-    }.to raise_error(TypeError)
-  end
-
-  it "raises an error when trying to get what is not a Hash" do
-    @data.string = random_string(128)
-    @data.rewind
-
-    expect {
-      Hash.proton_data_get(@data)
-    }.to raise_error(TypeError)
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/spec/qpid/proton/message_spec.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/spec/qpid/proton/message_spec.rb b/proton-c/bindings/ruby/spec/qpid/proton/message_spec.rb
deleted file mode 100644
index 36e4695..0000000
--- a/proton-c/bindings/ruby/spec/qpid/proton/message_spec.rb
+++ /dev/null
@@ -1,638 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-require "spec_helper"
-
-module Qpid
-
-  module Proton
-
-    describe "A message" do
-
-      before (:each) do
-        @message = Qpid::Proton::Message.new
-      end
-
-      it "can be created" do
-        expect(@message).not_to be_nil
-      end
-
-      it "can be cleared" do
-        subject = random_string(16)
-        @message.subject = subject
-        expect(@message.subject).to eq(subject)
-        @message.clear
-        expect(@message.subject).not_to eq(subject)
-      end
-
-      it "can be durable" do
-        @message.durable = true
-        expect(@message.durable).to eq(true)
-        @message.durable = false
-        expect(@message.durable).to eq(false)
-      end
-
-      it "raises an error when setting durable to nil" do
-        expect {
-          @message.durable = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error when setting the priority to nil" do
-        expect {
-          @message.priority = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error when setting the priority to a non-number" do
-        expect {
-          @message.priority = "abck"
-        }.to raise_error(TypeError)
-      end
-
-      it "sets the priority to the integer portion when a float" do
-        priority = rand(100) / 10
-        @message.priority = priority
-        expect(@message.priority).to eq(priority.floor)
-      end
-
-      it "rejects a priority with too large of a value" do
-        expect {
-          @message.priority = (rand(100) + 256)
-        }.to raise_error(RangeError)
-      end
-
-      it "rejects a negative priority" do
-        expect {
-          @message.priority = (0 - (rand(255) + 1))
-        }.to raise_error(RangeError)
-      end
-
-      it "has a priority" do
-        priority = rand(256)
-        @message.priority = priority
-        expect(@message.priority).to eq(priority)
-      end
-
-      it "raises an error when setting the time-to-live to nil" do
-        expect {
-          @message.ttl = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error when setting the time-to-live to a non-number" do
-        expect {
-          @message.ttl = random_string(5)
-        }.to raise_error(TypeError)
-      end
-
-      it "sets the time-to-live to the integer portion when a float" do
-        ttl = (rand(32767) / 10)
-        @message.ttl = ttl
-        expect(@message.ttl).to eq(ttl.floor)
-      end
-
-      it "raises an error when the time-to-live is negative" do
-        expect {
-          @message.ttl = (0 - rand(1000))
-        }.to raise_error(RangeError)
-      end
-
-      it "has a time-to-live" do
-        ttl = rand(32767)
-        @message.ttl = ttl
-        expect(@message.ttl).to eq(ttl)
-      end
-
-      it "raises an error when setting first acquirer to nil" do
-        expect {
-          @message.first_acquirer = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises and error when setting first acquirer to a non-boolean" do
-        expect {
-          @message.first_acquirer = random_string(16)
-        }.to raise_error(TypeError)
-      end
-
-      it "has a first acquirer" do
-        @message.first_acquirer = true
-        expect(@message.first_acquirer?).to eq(true)
-
-        @message.first_acquirer = false
-        expect(@message.first_acquirer?).to eq(false)
-      end
-
-      it "raises an error on a nil delivery count" do
-        expect {
-          @message.delivery_count = nil
-        }.to raise_error(::ArgumentError)
-      end
-
-      it "raises an error on a negative delivery count" do
-        expect {
-          @message.delivery_count = -1
-        }.to raise_error(RangeError)
-      end
-
-      it "raises an error on a non-numeric delivery count" do
-        expect {
-          @message.delivery_count = "farkle"
-        }.to raise_error(::ArgumentError)
-      end
-
-      it "converts a floating point delivery count to its integer portion" do
-          count = rand(255) / 10.0
-          @message.delivery_count = count
-          expect(@message.delivery_count).to eq(count.floor)
-        end
-
-      it "has a delivery count" do
-        count = rand(255)
-        @message.delivery_count = count
-        expect(@message.delivery_count).to eq(count)
-      end
-
-      it "allows setting a nil id" do
-        @message.id = nil
-        expect(@message.id).to be_nil
-      end
-
-      it "has an id" do
-        id = random_string(16)
-        @message.id = id
-        expect(@message.id).to eq(id)
-      end
-
-      it "allows setting a nil user id" do
-        @message.user_id = nil
-        expect(@message.user_id).to eq("")
-      end
-
-      it "has a user id" do
-        id = random_string(16)
-        @message.user_id = id
-        expect(@message.user_id).to eq(id)
-      end
-
-      it "allows setting a nil address" do
-        @message.address = nil
-        expect(@message.address).to be_nil
-      end
-
-      it "has an address" do
-        address = "//0.0.0.0/#{random_string(16)}"
-        @message.address = address
-        expect(@message.address).to eq(address)
-      end
-
-      it "allows setting a nil subject" do
-        @message.subject = nil
-        expect(@message.subject).to be_nil
-      end
-
-      it "has a subject" do
-        subject = random_string(50)
-        @message.subject = subject
-        expect(@message.subject).to eq(subject)
-      end
-
-      it "will allow a nil reply-to address" do
-        @message.reply_to = nil
-        expect(@message.reply_to).to be_nil
-      end
-
-      it "has a reply-to address" do
-        address = "//0.0.0.0/#{random_string(16)}"
-        @message.reply_to = address
-        expect(@message.reply_to).to eq(address)
-      end
-
-      it "will allow a nil correlation id" do
-        @message.correlation_id = nil
-        expect(@message.correlation_id).to be_nil
-      end
-
-      it "has a correlation id" do
-        id = random_string(25)
-        @message.correlation_id = id
-        expect(@message.correlation_id).to eq(id)
-      end
-
-      it "will allow a nil content type" do
-        @message.content_type = nil
-        expect(@message.content_type).to be_nil
-      end
-
-      it "will allow an empty content type" do
-        @message.content_type = ""
-        expect(@message.content_type).to eq("")
-      end
-
-      it "has a content type" do
-        content_type = random_string(32)
-        @message.content_type = content_type
-        expect(@message.content_type).to eq(content_type)
-      end
-
-      it "can have nil content encoding" do
-        @message.content_encoding = nil
-        expect(@message.content_encoding).to be_nil
-      end
-
-      it "has a content encoding" do
-        encoding = "#{random_string(8)}/#{random_string(8)}"
-        @message.content_encoding = encoding
-        expect(@message.content_encoding).to eq(encoding)
-      end
-
-      it "raises an error on a nil expiry time" do
-        expect {
-          @message.expires = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error on a negative expiry time" do
-        expect {
-          @message.expires = (0-(rand(65535)))
-        }.to raise_error(::ArgumentError)
-      end
-
-      it "can have a zero expiry time" do
-        @message.expires = 0
-        expect(@message.expires).to equal(0)
-      end
-
-      it "has an expiry time" do
-        time = rand(65535)
-        @message.expires = time
-        expect(@message.expires).to eq(time)
-      end
-
-      it "raises an error on a nil creation time" do
-        expect {
-          @message.creation_time = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error on a negative creation time" do
-        expect {
-          @message.creation_time = (0 - rand(65535))
-        }.to raise_error(::ArgumentError)
-      end
-
-      it "can have a zero creation time" do
-        @message.creation_time = 0
-        expect(@message.creation_time).to eq(0)
-      end
-
-      it "has a creation time" do
-        time = rand(65535)
-        @message.creation_time = time
-        expect(@message.creation_time).to eq(time)
-      end
-
-      it "can have a nil group id" do
-        @message.group_id = nil
-        expect(@message.group_id).to be_nil
-      end
-
-      it "can have an empty group id" do
-        @message.group_id = ""
-        expect(@message.group_id).to eq("")
-      end
-
-      it "has a group id" do
-        id = random_string(16)
-        @message.group_id = id
-        expect(@message.group_id).to eq(id)
-      end
-
-
-      it "raises an error on a nil group sequence" do
-        expect {
-          @message.group_sequence = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "can have a negative group sequence" do
-        seq = (0 - rand(32767))
-        @message.group_sequence = seq
-        expect(@message.group_sequence).to eq(seq)
-      end
-
-      it "can have a zero group sequence" do
-        @message.group_sequence = 0
-        expect(@message.group_sequence).to eq(0)
-      end
-
-      it "has a group sequence" do
-        id = rand(32767)
-        @message.group_sequence = id
-        expect(@message.group_sequence).to eq(id)
-      end
-
-      it "can have a nil reply-to group id" do
-        @message.reply_to_group_id = nil
-        expect(@message.reply_to_group_id).to be_nil
-      end
-
-      it "can have an empty reply-to group id" do
-        @message.reply_to_group_id = ""
-        expect(@message.reply_to_group_id).to eq("")
-      end
-
-      it "has a reply-to group id" do
-        id = random_string(16)
-        @message.reply_to_group_id = id
-        expect(@message.reply_to_group_id).to eq(id)
-      end
-
-      it "has properties" do
-        expect(@message).to respond_to(:properties)
-        expect(@message).to respond_to(:properties=)
-        expect(@message).to respond_to(:[])
-        expect(@message).to respond_to(:[]=)
-
-        expect(@message.properties).to be_kind_of({}.class)
-      end
-
-      it "can replace the set of properties" do
-        values = random_hash(128)
-
-        @message.properties = values.clone
-        expect(@message.properties).to eq(values)
-      end
-
-      it "can set properties" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-      end
-
-      it "can update properties" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-
-        value = random_string(128)
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-      end
-
-      it "can hold a null property" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-
-        @message[name] = nil
-        expect(@message[name]).to be_nil
-      end
-
-      it "can delete a property" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-
-        @message.delete_property(name)
-        expect(@message.properties.keys).to_not include(name)
-      end
-
-      it "has no properties after being cleared" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message[name] = value
-        expect(@message[name]).to eq(value)
-
-        @message.clear
-        expect(@message.properties).to be_empty
-      end
-
-      it "has instructions" do
-        expect(@message).to respond_to(:instructions)
-        expect(@message).to respond_to("instructions=".to_sym)
-      end
-
-      it "can set an instruction" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message.instructions[name] = value
-        expect(@message.instructions[name]).to eq(value)
-      end
-
-      it "can update an instruction" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message.instructions[name] = value
-        expect(@message.instructions[name]).to eq(value)
-
-        value = random_string(128)
-        @message.instructions[name] = value
-        expect(@message.instructions[name]).to eq(value)
-      end
-
-      it "can delete the instructions" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message.instructions[name] = value
-        expect(@message.instructions).to_not be_empty
-
-        @message.instructions = nil
-        expect(@message.instructions).to be_nil
-      end
-
-      it "can replace the instructions" do
-        values = random_hash(rand(128) + 1)
-
-        @message.instructions = values.clone
-        expect(@message.instructions).to eq(values)
-
-        values = random_hash(rand(64) + 1)
-
-        @message.instructions = values.clone
-        expect(@message.instructions).to eq(values)
-      end
-
-      it "can delete the set of instructions" do
-        values = random_hash(rand(128) + 1)
-
-        @message.instructions = values.clone
-        expect(@message.instructions).to eq(values)
-
-        @message.instructions = nil
-        expect(@message.instructions).to be_nil
-      end
-
-      it "has no instructions after being cleared" do
-        value = random_hash(128)
-
-        @message.instructions = value.clone
-        expect(@message.instructions).to eq(value)
-
-         @message.clear
-        expect(@message.instructions).to be_empty
-      end
-
-      it "has annotations" do
-        expect(@message).to respond_to(:annotations)
-        expect(@message).to respond_to(:annotations=)
-      end
-
-      it "can set an annotation" do
-        name = random_hash(32)
-        value = random_hash(256)
-
-        @message.annotations[name] = value.clone
-        expect(@message.annotations[name]).to eq(value)
-      end
-
-      it "can update an annotation" do
-        name = random_hash(32)
-        value = random_hash(256)
-
-        @message.annotations[name] = value.clone
-        expect(@message.annotations[name]).to eq(value)
-
-        value = random_hash(128)
-
-        @message.annotations[name] = value.clone
-        expect(@message.annotations[name]).to eq(value)
-      end
-
-      it "can delete an annotation" do
-        name = random_hash(32)
-        value = random_hash(256)
-
-        @message.annotations[name] = value.clone
-        expect(@message.annotations[name]).to eq(value)
-
-        @message.annotations[name] = nil
-        expect(@message.annotations[name]).to be_nil
-      end
-
-      it "can replace all annotations" do
-        values = random_hash(rand(128) + 1)
-
-        @message.annotations = values.clone
-        expect(@message.annotations).to eq(values)
-
-        values = random_hash(rand(64) + 1)
-
-        @message.annotations = values.clone
-        expect(@message.annotations).to eq(values)
-      end
-
-      it "can delete the set of annotations" do
-        value = random_hash(rand(128) + 1)
-
-        @message.annotations = value.clone
-        expect(@message.annotations).to eq(value)
-
-        @message.annotations = nil
-        expect(@message.annotations).to be_nil
-      end
-
-      it "has no annotations after being cleared" do
-        value = random_hash(16)
-
-        @message.annotations = value
-        expect(@message.annotations).to eq(value)
-
-        @message.clear
-        expect(@message.annotations).to be_empty
-      end
-
-      it "has a body property" do
-        expect(@message).to respond_to(:body)
-        expect(@message).to respond_to(:body=)
-      end
-
-      it "has a default body that is nil" do
-        expect(@message.body).to be_nil
-      end
-
-      it "has no body after being cleared" do
-        name = random_string(16)
-        value = random_string(128)
-
-        @message.body = value
-        expect(@message.body).to eq(value)
-
-        @message.clear
-        expect(@message.body).to be_nil
-      end
-
-      it "can set the body property" do
-        (1..3).each do |which|
-          case which
-            when 0
-            value = random_string(32)
-            when 1
-            value = random_array(100)
-            when 2
-            value = random_hash(100)
-            when 3
-            value = rand(512)
-          end
-
-          @message.body = value
-          expect(@message.body).to eq(value)
-        end
-      end
-
-      it "can update the body property" do
-        (1..3).each do |which|
-          case which
-            when 0
-            value = random_string(32)
-            when 1
-            value = random_array(100)
-            when 2
-            value = random_hash(100)
-            when 3
-            value = rand(512)
-          end
-
-          @message.body = value
-          expect(@message.body).to eq(value)
-
-          @message.body = nil
-          expect(@message.body).to be_nil
-        end
-      end
-
-    end
-
-  end
-
-end
-

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/spec/qpid/proton/messenger_spec.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/spec/qpid/proton/messenger_spec.rb b/proton-c/bindings/ruby/spec/qpid/proton/messenger_spec.rb
deleted file mode 100644
index 8e50331..0000000
--- a/proton-c/bindings/ruby/spec/qpid/proton/messenger_spec.rb
+++ /dev/null
@@ -1,407 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-require "spec_helper"
-
-module Qpid
-
-  module Proton
-
-    describe "A messenger" do
-
-      before (:each) do
-        @messenger = Qpid::Proton::Messenger::Messenger.new
-      end
-
-      after (:each) do
-        begin
-          @messenger.stop
-        rescue ProtonError => error
-          # ignore this error
-        end
-      end
-
-      it "will generate a name if one is not provided" do
-        expect(@messenger.name).to_not be_nil
-      end
-
-      it "will accept an assigned name" do
-        name = random_string(16)
-        msgr = Qpid::Proton::Messenger::Messenger.new(name)
-        expect(msgr.name).to eq(name)
-      end
-
-      it "raises an error on a nil timeout" do
-        expect {
-          @messenger.timeout = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "can have a negative timeout" do
-        timeout = (0 - rand(65535))
-        @messenger.timeout = timeout
-        expect(@messenger.timeout).to eq(timeout)
-      end
-
-      it "has a timeout" do
-        timeout = rand(65535)
-        @messenger.timeout = timeout
-        expect(@messenger.timeout).to eq(timeout)
-      end
-
-      it "has an error number" do
-        expect(@messenger.error?).to eq(false)
-        expect(@messenger.errno).to eq(0)
-        # force an error
-        expect {
-          @messenger.subscribe("amqp://~#{random_string}")
-        }.to raise_error(ProtonError)
-        expect(@messenger.error?).to eq(true)
-        expect(@messenger.errno).to_not eq(0)
-      end
-
-      it "has an error message" do
-        expect(@messenger.error?).to eq(false)
-        expect(@messenger.error).to be_nil
-        # force an error
-        expect {
-          @messenger.subscribe("amqp://~#{random_string}")
-        }.to raise_error(ProtonError)
-        expect(@messenger.error?).to eq(true)
-        expect(@messenger.errno).to_not be_nil
-      end
-
-      it "can be started" do
-        expect {
-          @messenger.start
-        }.to_not raise_error
-      end
-
-      it "can be stopped" do
-        expect {
-          @messenger.stop
-        }.to_not raise_error
-      end
-
-      it "raises an error when subscribing to a nil address" do
-        expect {
-          @messenger.subscribe(nil)
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error when subscribing to an invalid address" do
-        expect {
-          @messenger.subscribe("amqp://~#{random_string}")
-        }.to raise_error(ProtonError)
-        expect(@messenger.error?).to eq(true)
-        expect(@messenger.errno).to_not eq(nil)
-      end
-
-      it "can have a nil certificate" do
-        expect {
-          @messenger.certificate = nil
-          expect(@messenger.certificate).to be_nil
-        }.to_not raise_error
-      end
-
-      it "can have a certificate" do
-        cert = random_string(128)
-        @messenger.certificate = cert
-        expect(@messenger.certificate).to eq(cert)
-      end
-
-      it "can have a nil private key" do
-        expect {
-          @messenger.private_key = nil
-          expect(@messenger.private_key).to be_nil
-        }.to_not raise_error
-      end
-
-      it "can have a private key" do
-        key = random_string(128)
-        @messenger.private_key = key
-        expect(@messenger.private_key).to eq(key)
-      end
-
-      it "can have a nil trusted certificates" do
-        expect {
-          @messenger.trusted_certificates = nil
-          expect(@messenger.trusted_certificates).to be_nil
-        }.to_not raise_error
-      end
-
-      it "has a list of trusted certificates" do
-        certs = random_string(128)
-        @messenger.trusted_certificates = certs
-        expect(@messenger.trusted_certificates).to eq(certs)
-      end
-
-      it "raises an error on a nil outgoing window" do
-        expect {
-          @messenger.outgoing_window = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error on a non-numeric outgoing window" do
-        expect {
-          @messenger.outgoing_window = random_string(16)
-        }.to raise_error(TypeError)
-      end
-
-      it "can have a negative outgoing window" do
-        window = 0 - (rand(256) + 1)
-        @messenger.outgoing_window = window
-        expect(@messenger.outgoing_window).to eq(window)
-      end
-
-      it "can have a positive outgoing window" do
-        window = (rand(256) + 1)
-        @messenger.outgoing_window = window
-        expect(@messenger.outgoing_window).to eq(window)
-      end
-
-      it "can have a zero outgoing window" do
-        window = 0
-        @messenger.outgoing_window = window
-        expect(@messenger.outgoing_window).to eq(window)
-      end
-
-      it "raises an error on a nil incoming window" do
-        expect {
-          @messenger.incoming_window = nil
-        }.to raise_error(TypeError)
-      end
-
-      it "raises an error on a non-numeric incoming window" do
-        expect {
-          @messenger.incoming_window = random_string(16)
-        }.to raise_error(TypeError)
-      end
-
-      it "can have a negative incoming window" do
-        window = 0 - (rand(256) + 1)
-        @messenger.incoming_window = window
-        expect(@messenger.incoming_window).to eq(window)
-      end
-
-      it "can have a positive incoming window" do
-        window = (rand(256) + 1)
-        @messenger.incoming_window = window
-        expect(@messenger.incoming_window).to eq(window)
-      end
-
-      it "can have a zero incoming window" do
-        window = 0
-        @messenger.incoming_window = window
-        expect(@messenger.incoming_window).to eq(window)
-      end
-
-      it "can be put into passive mode" do
-        @messenger.passive = true
-        expect(@messenger.passive?).to eq(true)
-      end
-
-      it "can be taken out of passive mode" do
-        @messenger.passive = false
-        expect(@messenger.passive?).to eq(false)
-      end
-
-      it "can clear non-existent errors with failing" do
-        expect {
-          @messenger.clear_error
-        }.to_not raise_error
-      end
-
-      it "can clear errors" do
-        begin
-          @messenger.accept # should cause an error
-        rescue; end
-
-        expect(@messenger.error).to_not be_nil
-        @messenger.clear_error
-        expect(@messenger.error).to be_nil
-      end
-
-      describe "once started" do
-
-        before (:each) do
-          @messenger.start
-        end
-
-        after (:each) do
-          begin
-            @messenger.stop
-          rescue ProtonError => error
-            # ignore this error
-          end
-        end
-
-        it "can subscribe to an address" do
-          expect(@messenger.subscribe("amqp://~0.0.0.0:#{5700+rand(1024)}")).to_not be_nil
-        end
-
-        it "returns a tracker's status"
-
-        describe "and subscribed to an address" do
-
-          before (:each) do
-            # create a receiver
-            @port = 5700 + rand(1024)
-            @receiver = Qpid::Proton::Messenger::Messenger.new("receiver")
-            @receiver.subscribe("amqp://~0.0.0.0:#{@port}")
-            @messenger.timeout = 0
-            @receiver.timeout = 0
-            @receiver.start
-
-            Thread.new do
-              @receiver.receive(10)
-            end
-
-            @msg = Qpid::Proton::Message.new
-            @msg.address = "amqp://0.0.0.0:#{@port}"
-            @msg.body = "Test sent #{Time.new}"
-          end
-
-          after (:each) do
-            begin
-              @messenger.stop
-            rescue ProtonError => error
-              # ignore this error
-            end
-            begin
-              @receiver.stop
-            rescue
-            end
-          end
-
-          it "raises an error when queueing a nil message" do
-            expect {
-              @messenger.put(nil)
-            }.to raise_error(TypeError)
-          end
-
-          it "raises an error when queueing an invalid object" do
-            expect {
-              @messenger.put("This is not a message")
-            }.to raise_error(::ArgumentError)
-          end
-
-          it "can place a message in the outgoing queue" do
-            expect {
-              @messenger.put(@msg)
-            }.to_not raise_error
-          end
-
-          it "can send with an empty queue"
-
-          describe "with a an outgoing tracker" do
-
-            before(:each) do
-              @messenger.put(@msg)
-              @tracker = @messenger.outgoing_tracker
-            end
-
-            it "has an outgoing tracker" do
-              expect(@tracker).to_not be_nil
-            end
-
-            it "returns a tracker's status"
-
-            it "raises an error when settling with a nil tracker" do
-              expect {
-                @messenger.settle(nil)
-              }.to raise_error(TypeError)
-            end
-
-            it "can settle a tracker's status" do
-              @messenger.settle(@tracker)
-            end
-
-            it "raises an error when checking status on a nil tracker" do
-              expect {
-                @messenger.status(nil)
-              }.to raise_error(TypeError)
-            end
-
-            it "raises an error when checking status on an invalid tracker" do
-              expect {
-                @messenger.status(random_string(16))
-              }.to raise_error(TypeError)
-            end
-
-            it "can check the status of a tracker" do
-              expect(@messenger.status(@tracker)).to_not be_nil
-            end
-
-          end
-
-          it "has an incoming tracker"
-          it "can reject an incoming message"
-
-          it "raises an error when accepting with an invalid tracker" do
-            expect {
-              @messenger.accept(random_string(16))
-            }.to raise_error(TypeError)
-          end
-
-          it "can accept a message"
-
-          it "raises an error when rejecting with an invalid tracker" do
-            expect {
-              @messenger.accept(random_string(16))
-            }.to raise_error(TypeError)
-          end
-
-          describe "with messages sent" do
-
-            before (:each) do
-              @messenger.put(@msg)
-            end
-
-            it "can send messages"
-
-            it "raises an error when receiving with a nil max" do
-              expect {
-                @messenger.receive(nil)
-              }.to raise_error(TypeError)
-            end
-
-            it "raises an error when receiving with a non-numeric max" do
-              expect {
-                @messenger.receive("farkle")
-              }.to raise_error(TypeError)
-            end
-
-            it "can receive messages"
-            it "and create a new message when one wasn't provided"
-            it "can get a message from the incoming queue"
-            it "can tell how many outgoing messages are pending"
-            it "can tell how many incoming messages are queued"
-
-          end
-
-        end
-
-      end
-
-    end
-
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/spec/spec_helper.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/spec/spec_helper.rb b/proton-c/bindings/ruby/spec/spec_helper.rb
index 346cb0e..2698bb9 100644
--- a/proton-c/bindings/ruby/spec/spec_helper.rb
+++ b/proton-c/bindings/ruby/spec/spec_helper.rb
@@ -17,19 +17,8 @@
 # under the License.
 #
 
-begin
-  require "simplecov"
-  puts "simplecov available"
-
-  SimpleCov.start do
-    add_filter "/lib/*/*.rb"
-    add_filter "message_format.rb"
-  end
-
-rescue
-  puts "simplecov not available"
-end
-
+require 'minitest/spec'
+require 'minitest/autorun'
 require "securerandom"
 require "qpid_proton"
 
@@ -110,10 +99,10 @@ def random_array(length, described = false, description = nil)
 
   # create the array header
   case
-    when type == 0 then type = Qpid::Proton::Codec::INT
-    when type == 1 then type = Qpid::Proton::Codec::STRING
-    when type == 2 then type = Qpid::Proton::Codec::FLOAT
-    when type == 3 then type = Qpid::Proton::Codec::UUID
+  when type == 0 then type = Qpid::Proton::Codec::INT
+  when type == 1 then type = Qpid::Proton::Codec::STRING
+  when type == 2 then type = Qpid::Proton::Codec::DOUBLE
+  when type == 3 then type = Qpid::Proton::Codec::UUID
   end
 
   result.proton_array_header = Qpid::Proton::Types::ArrayHeader.new(type, description)
@@ -131,25 +120,3 @@ def random_hash(length)
   return result
 end
 
-# taken from http://stackoverflow.com/questions/6855944/rounding-problem-with-rspec-tests-when-comparing-float-arrays
-RSpec::Matchers.define :be_close_array do |expected, truth|
-  match do |actual|
-    same = 0
-    for i in 0..actual.length-1
-      same +=1 if actual[i].round(truth) == expected[i].round(truth)
-    end
-    same == actual.length
-  end
-
-  failure_message_for_should do |actual|
-    "expected that #{actual} would be close to #{expected}"
-  end
-
-  failure_message_for_should_not do |actual|
-    "expected that #{actual} would not be close to #{expected}"
-  end
-
-  description do
-    "be a close to #{expected}"
-  end
-end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/tests/test_container.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/tests/test_container.rb b/proton-c/bindings/ruby/tests/test_container.rb
index 7ed81b2..d5b5c9a 100644
--- a/proton-c/bindings/ruby/tests/test_container.rb
+++ b/proton-c/bindings/ruby/tests/test_container.rb
@@ -18,6 +18,7 @@
 #++
 
 require 'test_tools'
+require 'minitest/unit'
 
 Message = Qpid::Proton::Message
 SASL = Qpid::Proton::SASL

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/tests/test_interop.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/tests/test_interop.rb b/proton-c/bindings/ruby/tests/test_interop.rb
new file mode 100755
index 0000000..e08ada1
--- /dev/null
+++ b/proton-c/bindings/ruby/tests/test_interop.rb
@@ -0,0 +1,139 @@
+#!/usr/bin/env ruby
+
+require 'minitest/autorun'
+require 'minitest/unit'
+require 'qpid_proton'
+
+if ((RUBY_VERSION.split(".").map {|x| x.to_i}  <=> [1, 9]) < 0)
+  require 'pathname'
+  class File
+    def self.absolute_path(name)
+      return Pathname.new(name).realpath
+    end
+  end
+end
+
+class InteropTest < MiniTest::Test
+  Data = Qpid::Proton::Codec::Data
+  Message = Qpid::Proton::Message
+
+  def setup
+    @data = Data.new
+    @message = Message.new
+  end
+
+  # Walk up the directory tree to find the tests directory.
+  def get_data(name)
+    path = File.join(File.dirname(__FILE__), "../../../../tests/interop/#{name}.amqp")
+    raise "Can't find test/interop directory from #{__FILE__}" unless File.exists?(path)
+    File.open(path, "rb") { |f| f.read }
+  end
+
+  # Decode encoded bytes as a Data object
+  def decode_data(encoded)
+    buffer = encoded
+    while buffer.size > 0
+      n = @data.decode(buffer)
+      buffer = buffer[n..-1]
+    end
+    @data.rewind
+    reencoded = @data.encode
+    # Test the round-trip re-encoding gives the same result.
+    assert_equal(encoded, reencoded)
+  end
+
+  def decode_data_file(name) decode_data(get_data(name)); end
+
+  def decode_message_file(name)
+    message = Message.new()
+    message.decode(self.get_data(name))
+    self.decode_data(message.body)
+  end
+
+  def assert_next(type, value)
+    assert @data.next
+    assert_equal(type, @data.type)
+    assert_equal(value, type.get(@data))
+  end
+
+  def assert_array_next(expected, header)
+    assert_next(Qpid::Proton::Codec::ARRAY, expected)
+    result = @data.type.get(@data)
+    assert_equal(result.proton_array_header, header)
+  end
+
+  def test_message
+    decode_message_file("message")
+    assert_next(Qpid::Proton::Codec::STRING, "hello")
+    assert !@data.next
+  end
+
+  def test_primitives
+    decode_data_file("primitives")
+    assert_next(Qpid::Proton::Codec::BOOL, true)
+    assert_next(Qpid::Proton::Codec::BOOL, false)
+    assert_next(Qpid::Proton::Codec::UBYTE, 42)
+    assert_next(Qpid::Proton::Codec::USHORT, 42)
+    assert_next(Qpid::Proton::Codec::SHORT, -42)
+    assert_next(Qpid::Proton::Codec::UINT, 12345)
+    assert_next(Qpid::Proton::Codec::INT, -12345)
+    assert_next(Qpid::Proton::Codec::ULONG, 12345)
+    assert_next(Qpid::Proton::Codec::LONG, -12345)
+    assert_next(Qpid::Proton::Codec::FLOAT, 0.125)
+    assert_next(Qpid::Proton::Codec::DOUBLE, 0.125)
+    assert !@data.next
+  end
+
+  def test_strings
+    decode_data_file("strings")
+    assert_next(Qpid::Proton::Codec::BINARY, "abc\0defg")
+    assert_next(Qpid::Proton::Codec::STRING, "abcdefg")
+    assert_next(Qpid::Proton::Codec::SYMBOL, "abcdefg")
+    assert_next(Qpid::Proton::Codec::BINARY, "")
+    assert_next(Qpid::Proton::Codec::STRING, "")
+    assert_next(Qpid::Proton::Codec::SYMBOL, "")
+    assert !@data.next
+  end
+
+  def test_described
+    decode_data_file("described")
+    assert_next(Qpid::Proton::Codec::DESCRIBED, Qpid::Proton::Types::Described.new("foo-descriptor", "foo-value"))
+    assert(@data.described?)
+    assert_next(Qpid::Proton::Codec::DESCRIBED, Qpid::Proton::Types::Described.new(12, 13))
+    assert(@data.described?)
+    assert !@data.next
+  end
+
+  def test_described_array
+    decode_data_file("described_array")
+    assert_array_next((0...10).to_a,
+                       Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT,
+                                                     "int-array"))
+  end
+
+  def test_arrays
+    decode_data_file("arrays")
+    assert_array_next((0...100).to_a,
+                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT))
+    assert_array_next(["a", "b", "c"],
+                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::STRING))
+    assert_array_next([],
+                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT))
+    assert !@data.next
+  end
+
+  def test_lists
+    decode_data_file("lists")
+    assert_next(Qpid::Proton::Codec::LIST, [32, "foo", true])
+    assert_next(Qpid::Proton::Codec::LIST, [])
+    assert !@data.next
+  end
+
+  def test_maps
+    decode_data_file("maps")
+    assert_next(Qpid::Proton::Codec::MAP, {"one" => 1, "two" => 2, "three" => 3 })
+    assert_next(Qpid::Proton::Codec::MAP, {1 => "one", 2 => "two", 3 => "three"})
+    assert_next(Qpid::Proton::Codec::MAP, {})
+    assert !@data.next
+  end
+end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/tests/test_smoke.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/tests/test_smoke.rb b/proton-c/bindings/ruby/tests/test_smoke.rb
new file mode 100755
index 0000000..61cc7cf
--- /dev/null
+++ b/proton-c/bindings/ruby/tests/test_smoke.rb
@@ -0,0 +1,64 @@
+#!/usr/bin/env ruby
+
+require 'minitest/autorun'
+require 'minitest/unit'
+require 'qpid_proton'
+
+class SmokeTest < MiniTest::Test
+
+  Messenger = Qpid::Proton::Messenger::Messenger
+  Message = Qpid::Proton::Message
+
+  def setup
+    @server = Messenger.new()
+    @client = Messenger.new()
+    @server.blocking = false
+    @client.blocking = false
+    @server.subscribe("~0.0.0.0:12345")
+    @server.start()
+    @client.start()
+    pump()
+  end
+
+  def pump
+    while (@server.work(0) or @client.work(0)) do end
+  end
+
+  def teardown
+    @server.stop()
+    @client.stop()
+
+    pump()
+
+    assert @client.stopped?
+    assert @server.stopped?
+  end
+
+  def testSmoke(count=10)
+    msg = Message.new()
+    msg.address = "0.0.0.0:12345"
+
+    @server.receive()
+
+    count.times {|i|
+      msg.body = "Hello World! #{i}"
+      @client.put(msg)
+    }
+
+    msg2 = Message.new()
+
+    count.times {|i|
+      if (@server.incoming == 0) then
+        pump()
+      end
+      @server.get(msg2)
+      assert msg2.body == "Hello World! #{i}"
+    }
+
+    assert(@client.outgoing == 0,
+           "Expected 0 outgoing messages, found #{@client.outgoing}")
+    assert(@server.incoming == 0,
+           "Expected 0 incoming messages, found #{@server.incoming}")
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/proton-c/bindings/ruby/tests/test_tools.rb
----------------------------------------------------------------------
diff --git a/proton-c/bindings/ruby/tests/test_tools.rb b/proton-c/bindings/ruby/tests/test_tools.rb
index a48a508..2d8f3c6 100644
--- a/proton-c/bindings/ruby/tests/test_tools.rb
+++ b/proton-c/bindings/ruby/tests/test_tools.rb
@@ -17,7 +17,7 @@
 # under the License.
 #++
 
-# Tools for tests
+# Tools for tests. Only minitest is used.
 
 require 'minitest/autorun'
 require 'qpid_proton'
@@ -56,6 +56,19 @@ end
 
 class TestError < Exception; end
 
+def wait_port(port, timeout=5)
+  deadline = Time.now + timeout
+  begin  # Wait for the port to be connectible
+    TCPSocket.open("", $port).close
+  rescue Errno::ECONNREFUSED
+    if Time.now > deadline then
+      raise TestError("timed out waiting for port #{port}")
+    end
+    sleep(0.1)
+    retry
+  end
+end
+
 # Handler that creates its own container to run itself, and records some common
 # events that are checked by tests
 class TestHandler < MessagingHandler

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/tests/ruby/proton-test
----------------------------------------------------------------------
diff --git a/tests/ruby/proton-test b/tests/ruby/proton-test
deleted file mode 100755
index 04aee1c..0000000
--- a/tests/ruby/proton-test
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/usr/bin/env ruby
-
-if RUBY_VERSION < "1.9"
-require 'rubygems'
-end
-
-require 'test/unit'
-require 'proton_tests/interop.rb'
-require 'proton_tests/smoke.rb'

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/tests/ruby/proton_tests/interop.rb
----------------------------------------------------------------------
diff --git a/tests/ruby/proton_tests/interop.rb b/tests/ruby/proton_tests/interop.rb
deleted file mode 100755
index 1d50483..0000000
--- a/tests/ruby/proton_tests/interop.rb
+++ /dev/null
@@ -1,141 +0,0 @@
-#!/usr/bin/env ruby
-
-require 'test/unit'
-require 'qpid_proton'
-
-if ((RUBY_VERSION.split(".").map {|x| x.to_i}  <=> [1, 9]) < 0)
-  require 'pathname'
-  class File
-    def self.absolute_path(name)
-      return Pathname.new(name).realpath
-    end
-  end
-end
-
-class InteropTest < Test::Unit::TestCase
-  Data = Qpid::Proton::Codec::Data
-  Message = Qpid::Proton::Message
-
-  def setup
-    @data = Data.new
-    @message = Message.new
-  end
-
-  # Walk up the directory tree to find the tests directory.
-  def get_data(name)
-    path = File.absolute_path(__FILE__)
-    while path and File.basename(path) != "tests" do path = File.dirname(path); end
-    path = File.join(path,"interop")
-    raise "Can't find test/interop directory from #{__FILE__}" unless File.directory?(path)
-    path = File.join(path,"#{name}.amqp")
-    File.open(path, "rb") { |f| f.read }
-  end
-
-  # Decode encoded bytes as a Data object
-  def decode_data(encoded)
-    buffer = encoded
-    while buffer.size > 0
-      n = @data.decode(buffer)
-      buffer = buffer[n..-1]
-    end
-    @data.rewind
-    reencoded = @data.encode
-    # Test the round-trip re-encoding gives the same result.
-    assert_equal(encoded, reencoded)
-  end
-
-  def decode_data_file(name) decode_data(get_data(name)); end
-
-  def decode_message_file(name)
-    message = Message.new()
-    message.decode(self.get_data(name))
-    self.decode_data(message.body)
-  end
-
-  def assert_next(type, value)
-    assert @data.next
-    assert_equal(type, @data.type)
-    assert_equal(value, type.get(@data))
-  end
-
-  def assert_array_next(expected, header)
-    assert_next(Qpid::Proton::Codec::ARRAY, expected)
-    result = @data.type.get(@data)
-    assert_equal(result.proton_array_header, header)
-  end
-
-  def test_message
-    decode_message_file("message")
-    assert_next(Qpid::Proton::Codec::STRING, "hello")
-    assert !@data.next
-  end
-
-  def test_primitives
-    decode_data_file("primitives")
-    assert_next(Qpid::Proton::Codec::BOOL, true)
-    assert_next(Qpid::Proton::Codec::BOOL, false)
-    assert_next(Qpid::Proton::Codec::UBYTE, 42)
-    assert_next(Qpid::Proton::Codec::USHORT, 42)
-    assert_next(Qpid::Proton::Codec::SHORT, -42)
-    assert_next(Qpid::Proton::Codec::UINT, 12345)
-    assert_next(Qpid::Proton::Codec::INT, -12345)
-    assert_next(Qpid::Proton::Codec::ULONG, 12345)
-    assert_next(Qpid::Proton::Codec::LONG, -12345)
-    assert_next(Qpid::Proton::Codec::FLOAT, 0.125)
-    assert_next(Qpid::Proton::Codec::DOUBLE, 0.125)
-    assert !@data.next
-  end
-
-  def test_strings
-    decode_data_file("strings")
-    assert_next(Qpid::Proton::Codec::BINARY, "abc\0defg")
-    assert_next(Qpid::Proton::Codec::STRING, "abcdefg")
-    assert_next(Qpid::Proton::Codec::SYMBOL, "abcdefg")
-    assert_next(Qpid::Proton::Codec::BINARY, "")
-    assert_next(Qpid::Proton::Codec::STRING, "")
-    assert_next(Qpid::Proton::Codec::SYMBOL, "")
-    assert !@data.next
-  end
-
-  def test_described
-    decode_data_file("described")
-    assert_next(Qpid::Proton::Codec::DESCRIBED, Qpid::Proton::Types::Described.new("foo-descriptor", "foo-value"))
-    assert(@data.described?)
-    assert_next(Qpid::Proton::Codec::DESCRIBED, Qpid::Proton::Types::Described.new(12, 13))
-    assert(@data.described?)
-    assert !@data.next
-  end
-
-  def test_described_array
-    decode_data_file("described_array")
-    assert_array_next((0...10).to_a,
-                       Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT,
-                                                     "int-array"))
-  end
-
-  def test_arrays
-    decode_data_file("arrays")
-    assert_array_next((0...100).to_a,
-                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT))
-    assert_array_next(["a", "b", "c"],
-                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::STRING))
-    assert_array_next([],
-                      Qpid::Proton::Types::ArrayHeader.new(Qpid::Proton::Codec::INT))
-    assert !@data.next
-  end
-
-  def test_lists
-    decode_data_file("lists")
-    assert_next(Qpid::Proton::Codec::LIST, [32, "foo", true])
-    assert_next(Qpid::Proton::Codec::LIST, [])
-    assert !@data.next
-  end
-
-  def test_maps
-    decode_data_file("maps")
-    assert_next(Qpid::Proton::Codec::MAP, {"one" => 1, "two" => 2, "three" => 3 })
-    assert_next(Qpid::Proton::Codec::MAP, {1 => "one", 2 => "two", 3 => "three"})
-    assert_next(Qpid::Proton::Codec::MAP, {})
-    assert !@data.next
-  end
-end

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/5e1bce7a/tests/ruby/proton_tests/smoke.rb
----------------------------------------------------------------------
diff --git a/tests/ruby/proton_tests/smoke.rb b/tests/ruby/proton_tests/smoke.rb
deleted file mode 100755
index 5fc990a..0000000
--- a/tests/ruby/proton_tests/smoke.rb
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/usr/bin/env ruby
-
-require 'test/unit'
-require 'qpid_proton'
-
-class SmokeTest < Test::Unit::TestCase
-
-  Messenger = Qpid::Proton::Messenger::Messenger
-  Message = Qpid::Proton::Message
-
-  def setup
-    @server = Messenger.new()
-    @client = Messenger.new()
-    @server.blocking = false
-    @client.blocking = false
-    @server.subscribe("~0.0.0.0:12345")
-    @server.start()
-    @client.start()
-    pump()
-  end
-
-  def pump
-    while (@server.work(0) or @client.work(0)) do end
-  end
-
-  def teardown
-    @server.stop()
-    @client.stop()
-
-    pump()
-
-    assert @client.stopped?
-    assert @server.stopped?
-  end
-
-  def testSmoke(count=10)
-    msg = Message.new()
-    msg.address = "0.0.0.0:12345"
-
-    @server.receive()
-
-    count.times {|i|
-      msg.body = "Hello World! #{i}"
-      @client.put(msg)
-    }
-
-    msg2 = Message.new()
-
-    count.times {|i|
-      if (@server.incoming == 0) then
-        pump()
-      end
-      @server.get(msg2)
-      assert msg2.body == "Hello World! #{i}"
-    }
-
-    assert(@client.outgoing == 0,
-           "Expected 0 outgoing messages, found #{@client.outgoing}")
-    assert(@server.incoming == 0,
-           "Expected 0 incoming messages, found #{@server.incoming}")
-  end
-
-end


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


Mime
View raw message