spec/onstomp/interfaces/connection_events_spec.rb in onstomp-1.0.0pre1 vs spec/onstomp/interfaces/connection_events_spec.rb in onstomp-1.0.0
- old
+ new
@@ -41,13 +41,15 @@
let(:callback1) { mock('callback1') }
let(:callback2) { mock('callback2') }
let(:callback3) { mock('callback3') }
it "should bind events from the hash and trigger connected" do
+ eventable.stub(:version => 'x.y')
eventable.should_receive(:bind_event).with(:ev1, callback3)
eventable.should_receive(:bind_event).with(:ev1, callback2)
eventable.should_receive(:bind_event).with(:ev2, callback1)
- eventable.should_receive(:trigger_connection_event).with(:established)
+ eventable.should_receive(:trigger_connection_event).
+ with(:established, "STOMP x.y connection negotiated")
eventable.install_bindings_from_client :ev1 => [callback3, callback2],
:ev2 => [callback1]
end
end
end