spec/punchblock/command/accept_spec.rb in punchblock-0.5.1 vs spec/punchblock/command/accept_spec.rb in punchblock-0.6.0
- old
+ new
@@ -6,8 +6,16 @@
it 'registers itself' do
RayoNode.class_from_registration(:accept, 'urn:xmpp:rayo:1').should == Accept
end
it_should_behave_like 'command_headers'
+
+ describe "from a stanza" do
+ let(:stanza) { '<accept xmlns="urn:xmpp:rayo:1"/>' }
+
+ subject { RayoNode.import parse_stanza(stanza).root, '9f00061', '1' }
+
+ it { should be_instance_of Accept }
+ end
end
end
end # Punchblock