# HG changeset patch # User Matthew Wild # Date 1536248688 -3600 # Node ID c5267f5fd6e62a9ffb858f96889339a69892b849 # Parent 585ef5c1b226c8ccbd969dd5a9e6cf489a5ad61e spec/scansion: Add scansion scripts used for testing All past, except issue978-multi which fails randomly based on ordering of elements - this is a scansion issue to be resolved. diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/basic.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/basic.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,16 @@ +[Client] Romeo + jid: user@localhost + password: password + +--------- + +Romeo connects + +Romeo sends: + + +Romeo receives: + + +Romeo disconnects + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/basic_message.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/basic_message.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,174 @@ +# A script testing basic message routing and delivery + +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: juliet@localhost + password: password + +[Client] Juliet's phone + jid: juliet@localhost + password: password + resource: mobile + +--------- + +# Act 1, scene 1 +# The clients connect + +Romeo connects + +Juliet connects + +Juliet's phone connects + +# Romeo publishes his presence. Juliet has not, and so does not receive presence. + +Romeo sends: + + +Romeo receives: + + +# Romeo sends a message to Juliet's full JID + +Romeo sends: + + Hello Juliet! + + +Juliet receives: + + Hello Juliet! + + +# Romeo sends a message to Juliet's phone + +Romeo sends: + + Hello Juliet, on your phone. + + +Juliet's phone receives: + + Hello Juliet, on your phone. + + +# Scene 2 +# This requires the server to support offline messages (which is optional). + +# Romeo sends a message to Juliet's bare JID. This is not immediately delivered, as she +# has not published presence on either of her resources. + +Romeo sends: + + Hello Juliet, are you there? + + +# Juliet sends presence on her phone, and should receive the message there + +Juliet's phone sends: + + +Juliet's phone receives: + + +Juliet's phone receives: + + Hello Juliet, are you there? + + + +# Romeo sends another bare-JID message, it should be delivered +# instantly to Juliet's phone + +Romeo sends: + + Oh, hi! + + +Juliet's phone receives: + + Oh, hi! + + +# Juliet's laptop goes online, but with a negative priority + +Juliet sends: + + -1 + + +Juliet receives: + + -1 + + +Juliet's phone receives: + + -1 + + +# Again, Romeo sends a message to her bare JID, but it should +# only get delivered to her phone: + +Romeo sends: + + How are you? + + +Juliet's phone receives: + + How are you? + + +# Romeo sends direct to Juliet's full JID, and she should receive it + +Romeo sends: + + Are you hiding? + + +Juliet receives: + + Are you hiding? + + +# Juliet publishes non-negative presence + +Juliet sends: + + +Juliet receives: + + +Juliet's phone receives: + + +# And now Romeo's bare JID messages get delivered to both resources +# (server behaviour may vary here) + +Romeo sends: + + There! + + +Juliet receives: + + There! + + +Juliet's phone receives: + + There! + + +# The End + +Romeo disconnects + +Juliet disconnects + +Juliet's phone disconnects diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/basic_roster.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/basic_roster.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,39 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: juliet@localhost + password: password + +--------- + +Romeo connects + +Juliet connects + +Romeo sends: + + +Romeo receives: + + +Romeo sends: + + + + +Romeo receives: + + + + +Romeo disconnects + +#Juliet receives: +# +# +#Juliet receives: +# +# +#Juliet disconnects diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/issue505.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/issue505.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,77 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + +Romeo receives: + + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +Juliet sends: + + Farewell + + +Romeo receives: + + Farewell + + + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/issue978-multi.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/issue978-multi.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,109 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +[Client] Juliet's phone + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + +Romeo receives: + + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +# Juliet's phone connects, and joins the room +Juliet's phone connects + +Juliet's phone sends: + + + + +Juliet's phone receives: + + +Juliet's phone receives: + + +Juliet's phone receives: + + +Romeo receives: + + + + + + + +# Juliet leaves with an error +Juliet sends: + + + + Test error + + + +Romeo receives: + + + + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/issue978.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/issue978.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,84 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + anyone + + + + + +Romeo receives: + + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +Juliet sends: + + + + Test error + + + +Romeo receives: + + Kicked: service unavailable: Test error + + + + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/muc_mediated_invite.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_mediated_invite.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,74 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + +Romeo receives: + + + +# Juliet connects +Juliet connects + +Juliet sends: + + +Juliet receives: + + + +# Romeo invites Juliet to join the room + +Romeo sends: + + + + + + +Juliet receives: + + + + + + + room@conference.localhost/Romeo invited you to the room room@conference.localhost + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/muc_password-trunk.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_password-trunk.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,141 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + cauldronburn + + + + + +Romeo receives: + + + +# Juliet connects, and tries to join the room (password-protected) +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + + + + + +# Retry with the correct password +Juliet sends: + + + cauldronburn + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +# Ok, now Juliet leaves, and Romeo unsets the password + +Juliet sends: + + +Romeo receives: + + +Juliet receives: + + +# Remove room password +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + + + +# Config change success +Romeo receives: + + + +# Notification of room configuration update +Romeo receives: + + + + + + +# Juliet tries to join (should succeed) +Juliet sends: + + + + +# Notification of Romeo's presence in the room +Juliet receives: + + +Juliet receives: + + +# Room topic +Juliet receives: + + +Romeo receives: + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/muc_password.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_password.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,149 @@ +# MUC password test +# Ensures that setting and unsetting a MUC password works, and that the password is +# required to join a password-protected room. + +## prosody-0.9 result: fails because of missing 201 status code (related to issue #328) +## prosody-0.10 result: fails because of missing 201 status code (related to issue #328) + +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + cauldronburn + + + + + +Romeo receives: + + + +# Juliet connects, and tries to join the room (password-protected) +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + + + + + +# Retry with the correct password +Juliet sends: + + + cauldronburn + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +# Ok, now Juliet leaves, and Romeo unsets the password + +Juliet sends: + + +Romeo receives: + + +Juliet receives: + + +# Remove room password +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + + + + +# Config change success +Romeo receives: + + + +# Notification of room configuration update +Romeo receives: + + + + + + +# Juliet tries to join (should succeed) +Juliet sends: + + + + +# Notification of Romeo's presence in the room +Juliet receives: + + +Juliet receives: + + +# Room topic +Juliet receives: + + +Romeo receives: + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/muc_register.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_register.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,286 @@ +[Client] Romeo + jid: user@localhost + password: password + +[Client] Juliet + jid: user2@localhost + password: password + +[Client] Rosaline + jid: user3@localhost + password: password + +----- + +Romeo connects + +Romeo sends: + + + + +Romeo receives: + + + + + + + + +Romeo receives: + + +# Submit config form +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + + + +Romeo receives: + + + +Romeo sends: + + + + + + +Romeo receives: + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + +# Juliet retrieves the registration form + +Juliet sends: + + + + +Juliet receives: + + + + + http://jabber.org/protocol/muc#register + + + + + + +Juliet sends: + + + + + http://jabber.org/protocol/muc#register + + + Juliet + + + + + +Juliet receives: + + + + + + + +Juliet receives: + + +# Juliet discovers her reserved nick + +Juliet sends: + + + + +Juliet receives: + + + + + + +# Juliet leaves the room: + +Juliet sends: + + +Juliet receives: + + + + + + + +Romeo receives: + + + + + + +# Rosaline connect and tries to join the room as Juliet + +Rosaline connects + +Rosaline sends: + + + + +Rosaline receives: + + + + + + + +# In a heated moment, Juliet unregisters from the room + +Juliet sends: + + + + + + +Juliet receives: + + +# Rosaline attempts once more to sneak into the room, disguised as Juliet + +Rosaline sends: + + + + +Rosaline receives: + + + + + + +Rosaline receives: + + + + + + + +Romeo receives: + + + + + + +# On discovering the ruse, Romeo restores Juliet's nick and status within the room + +Romeo sends: + + + + + + +# Rosaline is evicted from the room + +Romeo receives: + + + + + This nickname is reserved + + + + +Romeo receives: + + +Rosaline receives: + + + + + This nickname is reserved + + + + + +# Rosaline, frustrated, attempts to get back into the room... + +Rosaline sends: + + + + +# ...but once again, is denied + +Rosaline receives: + + + + + + + +# Juliet, however, quietly joins the room with success + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/pubsub_advanced.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/pubsub_advanced.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,162 @@ +[Client] Balthasar + jid: admin@localhost + password: password + +[Client] Romeo + jid: romeo@localhost + password: password + +[Client] Juliet + jid: juliet@localhost + password: password + +--------- + +Romeo connects + +Romeo sends: + + + + + + +Romeo receives: + + + + + + +Balthasar connects + +Balthasar sends: + + + + + + +Balthasar receives: + + +Balthasar sends: + + + + + + +Balthasar receives: + + + + + + +Juliet connects + +Juliet sends: + + + + + + +Juliet receives: + + +Juliet sends: + + + + + + +Juliet receives: + + + + + + +Balthasar sends: + + + + + + +Balthasar receives: + + + + + + +Balthasar sends: + + + + + + + + +Balthasar receives: + + +Romeo sends: + + + + + + Soliloquy + Lorem ipsum dolor sit amet + + + + + + +Juliet receives: + + + + + + Soliloquy + Lorem ipsum dolor sit amet + + + + + + +Romeo receives: + + +Juliet sends: + + + + + + +Juliet receives: + + +Balthasar sends: + + + + + + +Balthasar receives: + + +Romeo disconnects + +// vim: syntax=xml: diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/pubsub_basic.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/pubsub_basic.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,102 @@ +[Client] Romeo + jid: admin@localhost + password: password + +// admin@localhost is assumed to have node creation privileges + +[Client] Juliet + jid: juliet@localhost + password: password + +--------- + +Romeo connects + +Romeo sends: + + + + + + +Romeo receives: + + +Juliet connects + +-- Juliet sends: +-- +-- +-- +-- +-- +-- +-- Juliet receives: +-- + +Juliet sends: + + + + + + +Juliet receives: + + +Romeo sends: + + + + + + Soliloquy + Lorem ipsum dolor sit amet + + + + + + +Romeo receives: + + +Juliet receives: + + + + + + Soliloquy + Lorem ipsum dolor sit amet + + + + + + +Juliet sends: + + + + + + +Juliet receives: + + +Juliet disconnects + +Romeo sends: + + + + + + +Romeo receives: + + +Romeo disconnects + +// vim: syntax=xml: diff -r 585ef5c1b226 -r c5267f5fd6e6 spec/scansion/pubsub_createdelete.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/pubsub_createdelete.scs Thu Sep 06 16:44:48 2018 +0100 @@ -0,0 +1,61 @@ +[Client] Romeo + jid: admin@localhost + password: password + +// admin@localhost is assumed to have node creation privileges + +--------- + +Romeo connects + +Romeo sends: + + + + + + +Romeo receives: + + +Romeo sends: + + + + + + +Romeo receives: + + + + + + +Romeo sends: + + + + + + +Romeo receives: + + +Romeo sends: + + + + + + +Romeo receives: + + + + + + +Romeo disconnects + +// vim: syntax=xml: