Sha256: ca33c442b3d8c662fe194f199eef63e1a46831796b3af586f1a2488be7ce5b58
Contents?: true
Size: 963 Bytes
Versions: 5
Compression:
Stored size: 963 Bytes
Contents
require 'spec_helper' describe DripDrop::Node do describe "initialization" do before(:all) do @ddn = DripDrop::Node.new { zmq_subscribe(rand_addr,:bind) #Keeps ZMQMachine Happy } @ddn.start sleep 1 end it "should start EventMachine" do EM.reactor_running?.should be_true end it "should start ZMQMachine" do pending "This is not repeatedly reliable" @ddn.zm_reactor.running?.should be_true end after do @ddn.stop rescue nil end end describe "shutdown" do before do @ddn = DripDrop::Node.new { zmq_subscribe(rand_addr,:bind) #Keeps ZMQMachine Happy } @ddn.start sleep 0.1 @ddn.stop rescue nil sleep 0.1 end it "should stop EventMachine" do EM.reactor_running?.should be_false end it "should stop ZMQMachine" do @ddn.zm_reactor.running?.should be_false end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
dripdrop-0.6.0 | spec/node_spec.rb |
dripdrop-0.5.0 | spec/node_spec.rb |
dripdrop-0.4.2 | spec/node_spec.rb |
dripdrop-0.4.1 | spec/node_spec.rb |
dripdrop-0.4.0 | spec/node_spec.rb |