aboutsummaryrefslogtreecommitdiffstats
path: root/spec/scansion
diff options
context:
space:
mode:
Diffstat (limited to 'spec/scansion')
-rw-r--r--spec/scansion/extdisco.scs8
-rw-r--r--spec/scansion/lastactivity.scs2
-rw-r--r--spec/scansion/mam_extended.scs16
-rw-r--r--spec/scansion/muc_outcast_reason.scs72
-rw-r--r--spec/scansion/muc_subject_issue_667.scs29
-rw-r--r--spec/scansion/pep_itemreply.scs205
-rw-r--r--spec/scansion/pep_nickname.scs2
-rw-r--r--spec/scansion/pep_publish_subscribe.scs6
-rw-r--r--spec/scansion/prosody.cfg.lua16
-rw-r--r--spec/scansion/pubsub_config.scs12
-rw-r--r--spec/scansion/pubsub_max_items.scs12
-rw-r--r--spec/scansion/pubsub_multi_items.scs12
-rw-r--r--spec/scansion/pubsub_preconditions.scs15
-rw-r--r--spec/scansion/uptime.scs2
-rw-r--r--spec/scansion/vcard_temp.scs4
15 files changed, 381 insertions, 32 deletions
diff --git a/spec/scansion/extdisco.scs b/spec/scansion/extdisco.scs
index f0781dc5..f2c8139f 100644
--- a/spec/scansion/extdisco.scs
+++ b/spec/scansion/extdisco.scs
@@ -17,8 +17,8 @@ Romeo receives:
<iq type='result' id='lx2' from='localhost'>
<services xmlns='urn:xmpp:extdisco:2'>
<service host='default.example' transport='udp' port='9876' type='stun'/>
- <service port='9876' type='turn' restricted='1' password='yHYYBDN7M3mdlug0LTdJbW0GvvQ=' transport='udp' host='default.example' username='1219525744'/>
- <service port='9876' type='turn' restricted='1' password='1Uc6QfrDhIlbK97rGCUQ/cUICxs=' transport='udp' host='default.example' username='1219525744'/>
+ <service port='9876' type='turn' restricted='1' password='{scansion:any}' transport='udp' host='default.example' username='{scansion:any}'/>
+ <service port='9876' type='turn' restricted='1' password='{scansion:any}' transport='udp' host='default.example' username='{scansion:any}'/>
<service port='2121' type='ftp' restricted='1' password='password' transport='tcp' host='default.example' username='john'/>
<service port='21' type='ftp' restricted='1' password='password' transport='tcp' host='ftp.example.com' username='john'/>
</services>
@@ -47,8 +47,8 @@ Romeo sends:
Romeo receives:
<iq type='result' id='lx4' from='localhost'>
<credentials xmlns='urn:xmpp:extdisco:2'>
- <service port='9876' type='turn' restricted='1' password='yHYYBDN7M3mdlug0LTdJbW0GvvQ=' transport='udp' host='default.example' username='1219525744'/>
- <service port='9876' type='turn' restricted='1' password='1Uc6QfrDhIlbK97rGCUQ/cUICxs=' transport='udp' host='default.example' username='1219525744'/>
+ <service port='9876' type='turn' restricted='1' password='{scansion:any}' transport='udp' host='default.example' username='{scansion:any}'/>
+ <service port='9876' type='turn' restricted='1' password='{scansion:any}' transport='udp' host='default.example' username='{scansion:any}'/>
</credentials>
</iq>
diff --git a/spec/scansion/lastactivity.scs b/spec/scansion/lastactivity.scs
index 44f4e516..4b8c8573 100644
--- a/spec/scansion/lastactivity.scs
+++ b/spec/scansion/lastactivity.scs
@@ -37,7 +37,7 @@ Romeo sends:
Romeo receives:
<iq type='result' id='a'>
- <query xmlns='jabber:iq:last' seconds='0'>Goodbye</query>
+ <query xmlns='jabber:iq:last' seconds='{scansion:any}'>Goodbye</query>
</iq>
Romeo disconnects
diff --git a/spec/scansion/mam_extended.scs b/spec/scansion/mam_extended.scs
index 2c6840df..e79eba95 100644
--- a/spec/scansion/mam_extended.scs
+++ b/spec/scansion/mam_extended.scs
@@ -45,8 +45,8 @@ Romeo sends:
Romeo receives:
<iq type="result" id="mamextmeta">
<metadata xmlns="urn:xmpp:mam:2">
- <start timestamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:mam:2" id="{scansion:any}"/>
- <end timestamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:mam:2" id="{scansion:any}"/>
+ <start timestamp="{scansion:capture:start}" xmlns="urn:xmpp:mam:2" id="{scansion:capture:first}"/>
+ <end timestamp="{scansion:capture:end}" xmlns="urn:xmpp:mam:2" id="{scansion:capture:last}"/>
</metadata>
</iq>
@@ -57,9 +57,9 @@ Romeo sends:
Romeo receives:
<message to="${Romeo's full JID}">
- <result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:any}">
+ <result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:capture:first}">
<forwarded xmlns="urn:xmpp:forward:0">
- <delay stamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:delay"/>
+ <delay stamp="{scansion:capture:start}" xmlns="urn:xmpp:delay"/>
<message to="someone@localhost" xmlns="jabber:client" type="chat" xml:lang="en" id="chat01" from="${Romeo's full JID}">
<body>Hello</body>
</message>
@@ -69,9 +69,9 @@ Romeo receives:
Romeo receives:
<message to="${Romeo's full JID}">
- <result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:any}">
+ <result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:capture:last}">
<forwarded xmlns="urn:xmpp:forward:0">
- <delay stamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:delay"/>
+ <delay stamp="{scansion:capture:end}" xmlns="urn:xmpp:delay"/>
<message to="someone@localhost" xmlns="jabber:client" type="chat" xml:lang="en" id="chat02" from="${Romeo's full JID}">
<body>U there?</body>
</message>
@@ -98,7 +98,7 @@ Romeo receives:
<message to="${Romeo's full JID}">
<result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:any}">
<forwarded xmlns="urn:xmpp:forward:0">
- <delay stamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:delay"/>
+ <delay stamp="{scansion:capture:start}" xmlns="urn:xmpp:delay"/>
<message to="someone@localhost" xmlns="jabber:client" type="chat" xml:lang="en" id="chat02" from="${Romeo's full JID}">
<body>U there?</body>
</message>
@@ -110,7 +110,7 @@ Romeo receives:
<message to="${Romeo's full JID}">
<result xmlns="urn:xmpp:mam:2" queryid="q1" id="{scansion:any}">
<forwarded xmlns="urn:xmpp:forward:0">
- <delay stamp="2008-08-22T21:09:04Z" xmlns="urn:xmpp:delay"/>
+ <delay stamp="{scansion:capture:end}" xmlns="urn:xmpp:delay"/>
<message to="someone@localhost" xmlns="jabber:client" type="chat" xml:lang="en" id="chat01" from="${Romeo's full JID}">
<body>Hello</body>
</message>
diff --git a/spec/scansion/muc_outcast_reason.scs b/spec/scansion/muc_outcast_reason.scs
new file mode 100644
index 00000000..e2725653
--- /dev/null
+++ b/spec/scansion/muc_outcast_reason.scs
@@ -0,0 +1,72 @@
+# Save ban reason
+
+[Client] Romeo
+ password: password
+ jid: user@localhost
+
+-----
+
+Romeo connects
+
+Romeo sends:
+ <presence to="muc-outcast-reason@conference.localhost/Romeo">
+ <x xmlns="http://jabber.org/protocol/muc"/>
+ </presence>
+
+Romeo receives:
+ <presence from="muc-outcast-reason@conference.localhost/Romeo">
+ <x xmlns="http://jabber.org/protocol/muc#user">
+ <status code="201"/>
+ <item jid="${Romeo's full JID}" role="moderator" affiliation="owner"/>
+ <status code="110"/>
+ </x>
+ </presence>
+
+Romeo receives:
+ <message type="groupchat" from="muc-outcast-reason@conference.localhost">
+ <subject/>
+ </message>
+
+Romeo sends:
+ <iq id="lx5" to="muc-outcast-reason@conference.localhost" type="set">
+ <query xmlns="http://jabber.org/protocol/muc#admin">
+ <item affiliation="outcast" jid="tybalt@localhost">
+ <reason>Hey calm down</reason>
+ </item>
+ </query>
+ </iq>
+
+Romeo receives:
+ <message from="muc-outcast-reason@conference.localhost">
+ <x xmlns="http://jabber.org/protocol/muc#user">
+ <status code="301"/>
+ <item jid="tybalt@localhost" affiliation="outcast">
+ <reason>Hey calm down</reason>
+ </item>
+ </x>
+ </message>
+
+Romeo receives:
+ <iq id="lx5" type="result" from="muc-outcast-reason@conference.localhost"/>
+
+Romeo sends:
+ <iq id="lx6" to="muc-outcast-reason@conference.localhost" type="get">
+ <query xmlns="http://jabber.org/protocol/muc#admin">
+ <item affiliation="outcast"/>
+ </query>
+ </iq>
+
+Romeo receives:
+ <iq id="lx6" type="result" from="muc-outcast-reason@conference.localhost">
+ <query xmlns="http://jabber.org/protocol/muc#admin">
+ <item jid="tybalt@localhost" affiliation="outcast">
+ <reason>Hey calm down</reason>
+ </item>
+ </query>
+ </iq>
+
+Romeo disconnects
+
+Romeo sends:
+ <presence type='unavailable'/>
+
diff --git a/spec/scansion/muc_subject_issue_667.scs b/spec/scansion/muc_subject_issue_667.scs
index 74980073..a4544ce4 100644
--- a/spec/scansion/muc_subject_issue_667.scs
+++ b/spec/scansion/muc_subject_issue_667.scs
@@ -42,6 +42,21 @@ Romeo receives:
<body>Hello everyone</body>
</message>
+# this should be treated as a normal message
+Romeo sends:
+ <message to="issue667@conference.localhost" type="groupchat">
+ <subject>New thread</subject>
+ <thread>498acea5-5894-473f-b4c6-c77319d11c75</thread>
+ <store xmlns="urn:xmpp:hints"/>
+ </message>
+
+Romeo receives:
+ <message type="groupchat" from="issue667@conference.localhost/Romeo">
+ <subject>New thread</subject>
+ <thread>498acea5-5894-473f-b4c6-c77319d11c75</thread>
+ <store xmlns="urn:xmpp:hints"/>
+ </message>
+
# Resync
Romeo sends:
<presence to="issue667@conference.localhost/Romeo">
@@ -63,6 +78,13 @@ Romeo receives:
<body>Hello everyone</body>
</message>
+Romeo receives:
+ <message type="groupchat" from="issue667@conference.localhost/Romeo">
+ <subject>New thread</subject>
+ <thread>498acea5-5894-473f-b4c6-c77319d11c75</thread>
+ <store xmlns="urn:xmpp:hints"/>
+ </message>
+
# the still empty subject
Romeo receives:
<message type="groupchat" from="issue667@conference.localhost">
@@ -116,6 +138,13 @@ Romeo receives:
Romeo receives:
<message type="groupchat" from="issue667@conference.localhost/Romeo">
+ <subject>New thread</subject>
+ <thread>498acea5-5894-473f-b4c6-c77319d11c75</thread>
+ <store xmlns="urn:xmpp:hints"/>
+ </message>
+
+Romeo receives:
+ <message type="groupchat" from="issue667@conference.localhost/Romeo">
<body>Lorem ipsum dolor sit amet</body>
</message>
diff --git a/spec/scansion/pep_itemreply.scs b/spec/scansion/pep_itemreply.scs
new file mode 100644
index 00000000..878b9e99
--- /dev/null
+++ b/spec/scansion/pep_itemreply.scs
@@ -0,0 +1,205 @@
+# PEP itemreply (publisher) configuration
+# This tests that itemreply == "publisher" will add the 'publisher' attribute
+# to notifications. Since this is not the default behaviour, the normal
+# publish and subscribe test cases cover testing that it is not included
+# otherwise.
+
+[Client] Romeo
+ jid: pep-test-df6zdvkv@localhost
+ password: password
+
+[Client] Juliet
+ jid: pep-test-5k90xvps@localhost
+ password: password
+
+-----
+
+Romeo connects
+
+Romeo sends:
+ <presence>
+ <c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/>
+ </presence>
+
+Romeo receives:
+ <iq type='get' id='disco' from="${Romeo's JID}">
+ <query node='http://code.matthewwild.co.uk/verse/#PDH7CGVPRERS2WUqBD18PHGEzaY=' xmlns='http://jabber.org/protocol/disco#info'/>
+ </iq>
+
+Romeo receives:
+ <presence from="${Romeo's full JID}">
+ <c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/>
+ </presence>
+
+Romeo sends:
+ <iq type='get' id='6'>
+ <query ver='' xmlns='jabber:iq:roster'/>
+ </iq>
+
+Romeo receives:
+ <iq type='result' id='6'>
+ <query ver='1' xmlns='jabber:iq:roster'/>
+ </iq>
+
+Juliet connects
+
+Juliet sends:
+ <presence>
+ <c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/>
+ </presence>
+
+Juliet receives:
+ <iq type='get' id='disco' from="${Juliet's JID}">
+ <query node='http://code.matthewwild.co.uk/verse/#PDH7CGVPRERS2WUqBD18PHGEzaY=' xmlns='http://jabber.org/protocol/disco#info'/>
+ </iq>
+
+Juliet receives:
+ <presence from="${Juliet's full JID}">
+ <c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/>
+ </presence>
+
+Juliet sends:
+ <iq type='get' id='6'>
+ <query ver='' xmlns='jabber:iq:roster'/>
+ </iq>
+
+Juliet receives:
+ <iq type='result' id='6'>
+ <query ver='1' xmlns='jabber:iq:roster'/>
+ </iq>
+
+Romeo sends:
+ <iq type='result' id='disco' to='pep-test-df6zdvkv@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#PDH7CGVPRERS2WUqBD18PHGEzaY='><identity type='pc' name='Verse' category='client'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='http://jabber.org/protocol/caps'/></query></iq>
+
+Romeo sends:
+ <presence type='subscribe' to="${Juliet's JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='set' id='{scansion:any}'><query ver='1' xmlns='jabber:iq:roster'><item ask='subscribe' jid='pep-test-5k90xvps@localhost' subscription='none'/></query></iq>
+
+Romeo receives:
+ <presence type='unavailable' to='pep-test-df6zdvkv@localhost' from='pep-test-5k90xvps@localhost'/>
+
+Juliet receives:
+ <presence type='subscribe' from='pep-test-df6zdvkv@localhost' to='pep-test-5k90xvps@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Juliet sends:
+ <iq type='result' id='disco' to='pep-test-5k90xvps@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#PDH7CGVPRERS2WUqBD18PHGEzaY='><identity type='pc' name='Verse' category='client'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='http://jabber.org/protocol/caps'/></query></iq>
+
+Juliet sends:
+ <presence type='subscribe' to="${Romeo's JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Juliet receives:
+ <iq type='set' id='{scansion:any}'><query ver='2' xmlns='jabber:iq:roster'><item ask='subscribe' jid='pep-test-df6zdvkv@localhost' subscription='none'/></query></iq>
+
+Juliet receives:
+ <presence type='unavailable' to='pep-test-5k90xvps@localhost' from='pep-test-df6zdvkv@localhost'/>
+
+Romeo receives:
+ <presence type='subscribe' from='pep-test-5k90xvps@localhost' to='pep-test-df6zdvkv@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo sends:
+ <iq type='result' id='fixme'/>
+
+Romeo sends:
+ <presence type='subscribed' to='pep-test-5k90xvps@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='set' id='{scansion:any}'><query ver='3' xmlns='jabber:iq:roster'><item ask='subscribe' jid='pep-test-5k90xvps@localhost' subscription='from'/></query></iq>
+
+Juliet receives:
+ <presence type='subscribed' from='pep-test-df6zdvkv@localhost' to='pep-test-5k90xvps@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Juliet receives:
+ <iq type='set' id='{scansion:any}'><query ver='3' xmlns='jabber:iq:roster'><item jid='pep-test-df6zdvkv@localhost' subscription='to'/></query></iq>
+
+Juliet receives:
+ <presence to='pep-test-5k90xvps@localhost' from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/><delay xmlns='urn:xmpp:delay' stamp='{scansion:any}' from='localhost'/></presence>
+
+Juliet sends:
+ <presence type='subscribed' to='pep-test-df6zdvkv@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Juliet receives:
+ <iq type='set' id='{scansion:any}'><query ver='4' xmlns='jabber:iq:roster'><item jid='pep-test-df6zdvkv@localhost' subscription='both'/></query></iq>
+
+Juliet receives:
+ <presence to='pep-test-5k90xvps@localhost' from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/><delay xmlns='urn:xmpp:delay' stamp='{scansion:any}' from='localhost'/></presence>
+
+Romeo receives:
+ <presence type='subscribed' from='pep-test-5k90xvps@localhost' to='pep-test-df6zdvkv@localhost'><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='set' id='{scansion:any}'><query ver='4' xmlns='jabber:iq:roster'><item jid='pep-test-5k90xvps@localhost' subscription='both'/></query></iq>
+
+Romeo receives:
+ <presence to='pep-test-df6zdvkv@localhost' from="${Juliet's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='PDH7CGVPRERS2WUqBD18PHGEzaY=' node='http://code.matthewwild.co.uk/verse/'/><delay xmlns='urn:xmpp:delay' stamp='{scansion:any}' from='localhost'/></presence>
+
+Juliet sends:
+ <iq type='result' id='fixme'/>
+
+Romeo sends:
+ <iq type='result' id='fixme'/>
+
+Romeo sends:
+ <iq type='result' id='fixme'/>
+
+Romeo sends:
+ <presence><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='m/sIsyfzKk8X1okZMtStR43nQQg=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='get' id='disco' from='pep-test-df6zdvkv@localhost'><query node='http://code.matthewwild.co.uk/verse/#m/sIsyfzKk8X1okZMtStR43nQQg=' xmlns='http://jabber.org/protocol/disco#info'/></iq>
+
+Romeo receives:
+ <presence from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='m/sIsyfzKk8X1okZMtStR43nQQg=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='get' id='disco' from='pep-test-5k90xvps@localhost'><query node='http://code.matthewwild.co.uk/verse/#m/sIsyfzKk8X1okZMtStR43nQQg=' xmlns='http://jabber.org/protocol/disco#info'/></iq>
+
+Juliet receives:
+ <presence from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='m/sIsyfzKk8X1okZMtStR43nQQg=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo sends:
+ <presence><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='IfQwbaaDB4LEP5tkGArEaB/3Y+s=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='get' id='disco' from='pep-test-df6zdvkv@localhost'><query node='http://code.matthewwild.co.uk/verse/#IfQwbaaDB4LEP5tkGArEaB/3Y+s=' xmlns='http://jabber.org/protocol/disco#info'/></iq>
+
+Romeo receives:
+ <presence from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='IfQwbaaDB4LEP5tkGArEaB/3Y+s=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Romeo receives:
+ <iq type='get' id='disco' from='pep-test-5k90xvps@localhost'><query node='http://code.matthewwild.co.uk/verse/#IfQwbaaDB4LEP5tkGArEaB/3Y+s=' xmlns='http://jabber.org/protocol/disco#info'/></iq>
+
+Romeo sends:
+ <iq type='result' id='disco' to='pep-test-df6zdvkv@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#m/sIsyfzKk8X1okZMtStR43nQQg='/></iq>
+
+Romeo sends:
+ <iq type='result' id='disco' to='pep-test-5k90xvps@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#m/sIsyfzKk8X1okZMtStR43nQQg='/></iq>
+
+Romeo sends:
+ <iq type='result' id='disco' to='pep-test-df6zdvkv@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#IfQwbaaDB4LEP5tkGArEaB/3Y+s='><identity type='pc' name='Verse' category='client'/><feature var='http://jabber.org/protocol/tune+notify'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='http://jabber.org/protocol/caps'/><feature var='http://jabber.org/protocol/mood+notify'/></query></iq>
+
+Juliet receives:
+ <presence from="${Romeo's full JID}"><c xmlns='http://jabber.org/protocol/caps' hash='sha-1' ver='IfQwbaaDB4LEP5tkGArEaB/3Y+s=' node='http://code.matthewwild.co.uk/verse/'/></presence>
+
+Juliet sends:
+ <iq type='result' id='fixme'/>
+
+Juliet sends:
+ <iq type='set' id='7'><pubsub xmlns='http://jabber.org/protocol/pubsub'><publish node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></publish><publish-options><x type='submit' xmlns='jabber:x:data'><field type='hidden' var='FORM_TYPE'><value>http://jabber.org/protocol/pubsub#publish-options</value></field><field var='pubsub#persist_items'><value>true</value></field><field var='pubsub#itemreply'><value>publisher</value></field></x></publish-options></pubsub></iq>
+
+Juliet receives:
+ <iq type='result' id='7' ><pubsub xmlns='http://jabber.org/protocol/pubsub'><publish node='http://jabber.org/protocol/tune'><item id='current'/></publish></pubsub></iq>
+
+Romeo receives:
+ <message type='headline' from='pep-test-5k90xvps@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
+
+Romeo sends:
+ <iq type='result' id='disco' to='pep-test-5k90xvps@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#IfQwbaaDB4LEP5tkGArEaB/3Y+s='><identity type='pc' name='Verse' category='client'/><feature var='http://jabber.org/protocol/tune+notify'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='http://jabber.org/protocol/caps'/><feature var='http://jabber.org/protocol/mood+notify'/></query></iq>
+
+Romeo receives:
+ <message type='headline' from='pep-test-5k90xvps@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
+
+Juliet disconnects
+
+Romeo disconnects
diff --git a/spec/scansion/pep_nickname.scs b/spec/scansion/pep_nickname.scs
index aaf53c87..1e39415b 100644
--- a/spec/scansion/pep_nickname.scs
+++ b/spec/scansion/pep_nickname.scs
@@ -58,7 +58,7 @@ Romeo receives:
<message type="headline" from="romeo@localhost">
<event xmlns="http://jabber.org/protocol/pubsub#event">
<items node="http://jabber.org/protocol/nick">
- <item id="current" publisher="${Romeo's JID}">
+ <item id="current">
<nickname xmlns="http://jabber.org/protocol/nick"/>
</item>
</items>
diff --git a/spec/scansion/pep_publish_subscribe.scs b/spec/scansion/pep_publish_subscribe.scs
index 6d33ffeb..e8080134 100644
--- a/spec/scansion/pep_publish_subscribe.scs
+++ b/spec/scansion/pep_publish_subscribe.scs
@@ -182,7 +182,7 @@ Juliet sends:
<iq type='result' id='fixme'/>
Juliet sends:
- <iq type='set' id='7'><pubsub xmlns='http://jabber.org/protocol/pubsub'><publish node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></publish></pubsub></iq>
+ <iq type='set' id='7'><pubsub xmlns='http://jabber.org/protocol/pubsub'><publish node='http://jabber.org/protocol/tune'><item id='current'><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></publish></pubsub></iq>
Juliet receives:
<iq type='result' id='7' ><pubsub xmlns='http://jabber.org/protocol/pubsub'><publish node='http://jabber.org/protocol/tune'><item id='current'/></publish></pubsub></iq>
@@ -197,13 +197,13 @@ Juliet sends:
<iq type='result' id='{scansion:any}'/>
Romeo receives:
- <message type='headline' from='pep-test-tqvqu_pv@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
+ <message type='headline' from='pep-test-tqvqu_pv@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current'><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
Romeo sends:
<iq type='result' id='disco' to='pep-test-tqvqu_pv@localhost'><query xmlns='http://jabber.org/protocol/disco#info' node='http://code.matthewwild.co.uk/verse/#IfQwbaaDB4LEP5tkGArEaB/3Y+s='><identity type='pc' name='Verse' category='client'/><feature var='http://jabber.org/protocol/tune+notify'/><feature var='http://jabber.org/protocol/disco#info'/><feature var='http://jabber.org/protocol/disco#items'/><feature var='http://jabber.org/protocol/caps'/><feature var='http://jabber.org/protocol/mood+notify'/></query></iq>
Romeo receives:
- <message type='headline' from='pep-test-tqvqu_pv@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current' publisher="${Juliet's JID}"><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
+ <message type='headline' from='pep-test-tqvqu_pv@localhost'><event xmlns='http://jabber.org/protocol/pubsub#event'><items node='http://jabber.org/protocol/tune'><item id='current'><tune xmlns='http://jabber.org/protocol/tune'><title>Beautiful Cedars</title><artist>The Spinners</artist><source>Not Quite Folk</source><track>4</track></tune></item></items></event></message>
Juliet disconnects
diff --git a/spec/scansion/prosody.cfg.lua b/spec/scansion/prosody.cfg.lua
index 6901cc11..48183fc7 100644
--- a/spec/scansion/prosody.cfg.lua
+++ b/spec/scansion/prosody.cfg.lua
@@ -1,20 +1,9 @@
--luacheck: ignore
--- Mock time functions to simplify tests
-function _G.os.time()
- return 1219439344;
-end
-package.preload["util.time"] = function ()
- return {
- now = function () return 1219439344.1; end;
- monotonic = function () return 0.1; end;
- }
-end
-
admins = { "admin@localhost" }
network_backend = ENV_PROSODY_NETWORK_BACKEND or "epoll"
-network_settings = require"util.json".decode(ENV_PROSODY_NETWORK_SETTINGS or "{}")
+network_settings = Lua.require"prosody.util.json".decode(ENV_PROSODY_NETWORK_SETTINGS or "{}")
modules_enabled = {
-- Generally required
@@ -66,6 +55,9 @@ modules_enabled = {
"tombstones";
"user_account_management";
+ -- Required for integration testing
+ "debug_reset";
+
-- Useful for testing
--"scansion_record"; -- Records things that happen in scansion test case format
}
diff --git a/spec/scansion/pubsub_config.scs b/spec/scansion/pubsub_config.scs
index d06d864e..57f275cd 100644
--- a/spec/scansion/pubsub_config.scs
+++ b/spec/scansion/pubsub_config.scs
@@ -119,6 +119,18 @@ Romeo receives:
<field var="pubsub#notify_retract" label="Whether to notify subscribers when items are removed from the node" type="boolean">
<value>1</value>
</field>
+ <field label="Specify whose JID to include as the publisher of items" var="pubsub#itemreply" type="list-single">
+ <option label="Include the node owner's JID">
+ <value>owner</value>
+ </option>
+ <option label="Include the item publisher's JID">
+ <value>publisher</value>
+ </option>
+ <option label="Don't include any JID with items">
+ <value>none</value>
+ </option>
+ <value>none</value>
+ </field>
</x>
</configure>
</pubsub>
diff --git a/spec/scansion/pubsub_max_items.scs b/spec/scansion/pubsub_max_items.scs
index c5525bd3..31480b2e 100644
--- a/spec/scansion/pubsub_max_items.scs
+++ b/spec/scansion/pubsub_max_items.scs
@@ -114,6 +114,18 @@ Alice receives:
<field var="pubsub#notify_retract" label="Whether to notify subscribers when items are removed from the node" type="boolean">
<value>1</value>
</field>
+ <field label="Specify whose JID to include as the publisher of items" var="pubsub#itemreply" type="list-single">
+ <option label="Include the node owner's JID">
+ <value>owner</value>
+ </option>
+ <option label="Include the item publisher's JID">
+ <value>publisher</value>
+ </option>
+ <option label="Don't include any JID with items">
+ <value>none</value>
+ </option>
+ <value>none</value>
+ </field>
</x>
</configure>
</pubsub>
diff --git a/spec/scansion/pubsub_multi_items.scs b/spec/scansion/pubsub_multi_items.scs
index e43bc839..7f365b94 100644
--- a/spec/scansion/pubsub_multi_items.scs
+++ b/spec/scansion/pubsub_multi_items.scs
@@ -114,6 +114,18 @@ Alice receives:
<field var="pubsub#notify_retract" label="Whether to notify subscribers when items are removed from the node" type="boolean">
<value>1</value>
</field>
+ <field label="Specify whose JID to include as the publisher of items" var="pubsub#itemreply" type="list-single">
+ <option label="Include the node owner's JID">
+ <value>owner</value>
+ </option>
+ <option label="Include the item publisher's JID">
+ <value>publisher</value>
+ </option>
+ <option label="Don't include any JID with items">
+ <value>none</value>
+ </option>
+ <value>none</value>
+ </field>
</x>
</configure>
</pubsub>
diff --git a/spec/scansion/pubsub_preconditions.scs b/spec/scansion/pubsub_preconditions.scs
index 5c0c2569..286e84d6 100644
--- a/spec/scansion/pubsub_preconditions.scs
+++ b/spec/scansion/pubsub_preconditions.scs
@@ -118,6 +118,18 @@ Romeo receives:
<field var="pubsub#notify_retract" label="Whether to notify subscribers when items are removed from the node" type="boolean">
<value>1</value>
</field>
+ <field label="Specify whose JID to include as the publisher of items" var="pubsub#itemreply" type="list-single">
+ <option label="Include the node owner's JID">
+ <value>owner</value>
+ </option>
+ <option label="Include the item publisher's JID">
+ <value>publisher</value>
+ </option>
+ <option label="Don't include any JID with items">
+ <value>none</value>
+ </option>
+ <value>none</value>
+ </field>
</x>
</configure>
</pubsub>
@@ -199,6 +211,9 @@ Romeo sends:
<field var="pubsub#notify_retract" type="boolean" label="Whether to notify subscribers when items are removed from the node">
<value>1</value>
</field>
+ <field var="pubsub#itemreply" type="boolean">
+ <value>none</value>
+ </field>
</x>
</configure>
</pubsub>
diff --git a/spec/scansion/uptime.scs b/spec/scansion/uptime.scs
index 188b9eb5..ed83e51b 100644
--- a/spec/scansion/uptime.scs
+++ b/spec/scansion/uptime.scs
@@ -15,7 +15,7 @@ Romeo sends:
Romeo receives:
<iq type='result' id='a' from='localhost'>
- <query xmlns='jabber:iq:last' seconds='0'/>
+ <query xmlns='jabber:iq:last' seconds='{scansion:any}'/>
</iq>
Romeo disconnects
diff --git a/spec/scansion/vcard_temp.scs b/spec/scansion/vcard_temp.scs
index 38c6f755..240ea1f3 100644
--- a/spec/scansion/vcard_temp.scs
+++ b/spec/scansion/vcard_temp.scs
@@ -51,8 +51,6 @@ Romeo receives:
</vCard>
</iq>
-Romeo disconnects
-
Juliet connects
Juliet sends:
@@ -77,4 +75,6 @@ Juliet receives:
Juliet disconnects
+Romeo disconnects
+
# recording ended on 2018-10-20T15:02:14Z