# HG changeset patch # User Matthew Wild # Date 1545225915 0 # Node ID 0d97768b0ea966f7c33a8b2b576619941c6eea18 # Parent f31ed70c993adcb43808720d110e69c2b7b228b6 spec/scansion: Add tests for members-only rooms diff -r f31ed70c993a -r 0d97768b0ea9 spec/scansion/muc_members_only_change.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_members_only_change.scs Wed Dec 19 13:25:15 2018 +0000 @@ -0,0 +1,114 @@ +# MUC: Room registration and reserved nicknames + +[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, set the room to members-only +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + 1 + + + + + +Romeo receives: + + + +# Romeo adds Juliet to the member list +Romeo sends: + + + + + + +Romeo receives: + + + + + + +Romeo receives: + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + + +# Romeo removes Juliet's membership status +Romeo sends: + + + + + + +# As a non-member, Juliet must now be removed from the room +Romeo receives: + + + + + + + + + +Romeo receives: + + +Romeo disconnects + +Juliet disconnects diff -r f31ed70c993a -r 0d97768b0ea9 spec/scansion/muc_members_only_deregister.scs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/spec/scansion/muc_members_only_deregister.scs Wed Dec 19 13:25:15 2018 +0000 @@ -0,0 +1,122 @@ +# MUC: Room registration and reserved nicknames + +[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, set the room to members-only +Romeo sends: + + + + + http://jabber.org/protocol/muc#roomconfig + + + 1 + + + + + +Romeo receives: + + + +# Romeo adds Juliet to the member list +Romeo sends: + + + + + + +Romeo receives: + + + + + + +Romeo receives: + + +# Juliet connects, and joins the room +Juliet connects + +Juliet sends: + + + + +Juliet receives: + + +Juliet receives: + + +Juliet receives: + + +Romeo receives: + + + +# Tired of Romeo's company, Juliet unregisters from the room + +Juliet sends: + + + + + + +Juliet receives: + + + + + + + + +Juliet receives: + + +Romeo receives: + + + + + + + + +Romeo disconnects + +Juliet disconnects