Rename to slixmpp

This commit is contained in:
Florent Le Coz
2014-07-17 14:19:04 +02:00
parent e5582694c0
commit 5ab77c7452
514 changed files with 3473 additions and 3530 deletions

View File

@@ -1,16 +1,16 @@
import logging
from sleekxmpp.test import *
from slixmpp.test import *
class TestMultipleStreams(SleekTest):
class TestMultipleStreams(SlixTest):
"""
Test that we can test a live stanza stream.
"""
def setUp(self):
self.client1 = SleekTest()
self.client2 = SleekTest()
self.client1 = SlixTest()
self.client2 = SlixTest()
def tearDown(self):
self.client1.stream_close()

View File

@@ -1,9 +1,9 @@
import logging
from sleekxmpp.test import *
from slixmpp.test import *
class TestLiveStream(SleekTest):
class TestLiveStream(SlixTest):
"""
Test that we can test a live stanza stream.
"""

View File

@@ -1,9 +1,9 @@
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestEvents(SleekTest):
class TestEvents(SlixTest):
def setUp(self):
self.stream_start()

View File

@@ -1,12 +1,12 @@
# -*- encoding: utf8 -*-
from __future__ import unicode_literals
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp import JID, InvalidJID
from sleekxmpp.jid import nodeprep
from slixmpp.test import SlixTest
from slixmpp import JID, InvalidJID
from slixmpp.jid import nodeprep
class TestJIDClass(SleekTest):
class TestJIDClass(SlixTest):
"""Verify that the JID class can parse and manipulate JIDs."""

View File

@@ -14,7 +14,7 @@ class TestOverall(unittest.TestCase):
def testModules(self):
"""Testing all modules by compiling them"""
src = '.%ssleekxmpp' % os.sep
src = '.%sslixmpp' % os.sep
if sys.version_info < (3, 0):
rx = re.compile('/[.]svn')
else:
@@ -23,7 +23,7 @@ class TestOverall(unittest.TestCase):
def testTabNanny(self):
"""Testing that indentation is consistent"""
self.failIf(tabnanny.check('..%ssleekxmpp' % os.sep))
self.failIf(tabnanny.check('..%sslixmpp' % os.sep))
suite = unittest.TestLoader().loadTestsFromTestCase(TestOverall)

View File

@@ -1,7 +1,7 @@
import unittest
import logging
from sleekxmpp.plugins.base import PluginManager, BasePlugin, register_plugin
from slixmpp.plugins.base import PluginManager, BasePlugin, register_plugin
class A(BasePlugin):

View File

@@ -1,9 +1,9 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream.stanzabase import ET, StanzaBase
from slixmpp.test import SlixTest
from slixmpp.xmlstream.stanzabase import ET, StanzaBase
class TestStanzaBase(SleekTest):
class TestStanzaBase(SlixTest):
def testTo(self):
"""Test the 'to' interface of StanzaBase."""

View File

@@ -1,10 +1,10 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream.stanzabase import ElementBase, register_stanza_plugin, ET
from sleekxmpp.thirdparty import OrderedDict
from slixmpp.test import SlixTest
from slixmpp.xmlstream.stanzabase import ElementBase, register_stanza_plugin, ET
from slixmpp.thirdparty import OrderedDict
class TestElementBase(SleekTest):
class TestElementBase(SlixTest):
def testFixNs(self):
"""Test fixing namespaces in an XPath expression."""

View File

@@ -1,8 +1,8 @@
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestErrorStanzas(SleekTest):
class TestErrorStanzas(SlixTest):
def setUp(self):
# Ensure that the XEP-0086 plugin has been loaded.

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp import Iq
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.gmail_notify as gmail
from sleekxmpp.xmlstream import register_stanza_plugin, ET
from slixmpp import Iq
from slixmpp.test import SlixTest
import slixmpp.plugins.gmail_notify as gmail
from slixmpp.xmlstream import register_stanza_plugin, ET
class TestGmail(SleekTest):
class TestGmail(SlixTest):
def setUp(self):
register_stanza_plugin(Iq, gmail.GmailQuery)

View File

@@ -1,9 +1,9 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream.stanzabase import ET
from slixmpp.test import SlixTest
from slixmpp.xmlstream.stanzabase import ET
class TestIqStanzas(SleekTest):
class TestIqStanzas(SlixTest):
def tearDown(self):
"""Shutdown the XML stream after testing."""

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.stanza.message import Message
from sleekxmpp.stanza.htmlim import HTMLIM
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp.test import SlixTest
from slixmpp.stanza.message import Message
from slixmpp.stanza.htmlim import HTMLIM
from slixmpp.xmlstream import register_stanza_plugin
class TestMessageStanzas(SleekTest):
class TestMessageStanzas(SlixTest):
def setUp(self):
register_stanza_plugin(Message, HTMLIM)
@@ -29,12 +29,12 @@ class TestMessageStanzas(SleekTest):
def testHTMLPlugin(self):
"Test message/html/body stanza"
msg = self.Message()
msg['to'] = "fritzy@netflint.net/sleekxmpp"
msg['to'] = "fritzy@netflint.net/slixmpp"
msg['body'] = "this is the plaintext message"
msg['type'] = 'chat'
msg['html']['body'] = '<p>This is the htmlim message</p>'
self.check(msg, """
<message to="fritzy@netflint.net/sleekxmpp" type="chat">
<message to="fritzy@netflint.net/slixmpp" type="chat">
<body>this is the plaintext message</body>
<html xmlns="http://jabber.org/protocol/xhtml-im">
<body xmlns="http://www.w3.org/1999/xhtml">

View File

@@ -1,8 +1,8 @@
import unittest
import sleekxmpp
from sleekxmpp.test import SleekTest
import slixmpp
from slixmpp.test import SlixTest
class TestPresenceStanzas(SleekTest):
class TestPresenceStanzas(SlixTest):
def testPresenceShowRegression(self):
"""Regression check presence['type'] = 'dnd' show value working"""
@@ -38,7 +38,7 @@ class TestPresenceStanzas(SleekTest):
p['type'] = 'unavailable'
p['from'] = 'bill@chadmore.com/gmail15af'
c = sleekxmpp.ClientXMPP('crap@wherever', 'password')
c = slixmpp.ClientXMPP('crap@wherever', 'password')
happened = []
def handlechangedpresence(event):

View File

@@ -1,9 +1,9 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream import ET
from slixmpp.test import SlixTest
from slixmpp.xmlstream import ET
class TestRosterStanzas(SleekTest):
class TestRosterStanzas(SlixTest):
def testAddItems(self):
"""Test adding items to a roster stanza."""

View File

@@ -1,13 +1,13 @@
import unittest
from sleekxmpp import Message
from sleekxmpp.test import SleekTest
from sleekxmpp.thirdparty import OrderedDict
from slixmpp import Message
from slixmpp.test import SlixTest
from slixmpp.thirdparty import OrderedDict
import sleekxmpp.plugins.xep_0004 as xep_0004
from sleekxmpp.xmlstream import register_stanza_plugin
import slixmpp.plugins.xep_0004 as xep_0004
from slixmpp.xmlstream import register_stanza_plugin
class TestDataForms(SleekTest):
class TestDataForms(SlixTest):
def setUp(self):
register_stanza_plugin(Message, xep_0004.Form)

View File

@@ -1,9 +1,9 @@
# -*- encoding:utf-8 -*-
"""
SleekXMPP: The Sleek XMPP Library
Slixmpp: The Slick XMPP Library
Copyright (C) 2011 Nathanael C. Fritz, Dann Martens (TOMOTON).
This file is part of SleekXMPP.
This file is part of Slixmpp.
See the file LICENSE for copying permission.
"""
@@ -13,14 +13,14 @@ from __future__ import unicode_literals
import base64
import sys
from sleekxmpp.plugins.xep_0009.stanza.RPC import RPCQuery, MethodCall, \
from slixmpp.plugins.xep_0009.stanza.RPC import RPCQuery, MethodCall, \
MethodResponse
from sleekxmpp.plugins.xep_0009.binding import py2xml, xml2py, rpcbase64, \
from slixmpp.plugins.xep_0009.binding import py2xml, xml2py, rpcbase64, \
rpctime
from sleekxmpp.stanza.iq import Iq
from sleekxmpp.test.sleektest import SleekTest
from sleekxmpp.xmlstream.stanzabase import register_stanza_plugin
from sleekxmpp.xmlstream.tostring import tostring
from slixmpp.stanza.iq import Iq
from slixmpp.test.slixtest import SlixTest
from slixmpp.xmlstream.stanzabase import register_stanza_plugin
from slixmpp.xmlstream.tostring import tostring
import unittest
@@ -28,7 +28,7 @@ if sys.version_info > (3, 0):
unicode = str
class TestJabberRPC(SleekTest):
class TestJabberRPC(SlixTest):
def setUp(self):
register_stanza_plugin(Iq, RPCQuery)

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp import Iq
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.xep_0030 as xep_0030
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp import Iq
from slixmpp.test import SlixTest
import slixmpp.plugins.xep_0030 as xep_0030
from slixmpp.xmlstream import register_stanza_plugin
class TestDisco(SleekTest):
class TestDisco(SlixTest):
"""
Test creating and manipulating the disco#info and

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp import Message
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.xep_0033 as xep_0033
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp import Message
from slixmpp.test import SlixTest
import slixmpp.plugins.xep_0033 as xep_0033
from slixmpp.xmlstream import register_stanza_plugin
class TestAddresses(SleekTest):
class TestAddresses(SlixTest):
def setUp(self):
register_stanza_plugin(Message, xep_0033.Addresses)

View File

@@ -1,12 +1,12 @@
import unittest
from sleekxmpp.exceptions import XMPPError
from sleekxmpp import Iq
from sleekxmpp.test import SleekTest
from sleekxmpp.plugins.xep_0047 import Data
from sleekxmpp.xmlstream import register_stanza_plugin, ET
from slixmpp.exceptions import XMPPError
from slixmpp import Iq
from slixmpp.test import SlixTest
from slixmpp.plugins.xep_0047 import Data
from slixmpp.xmlstream import register_stanza_plugin, ET
class TestIBB(SleekTest):
class TestIBB(SlixTest):
def setUp(self):
register_stanza_plugin(Iq, Data)
@@ -82,7 +82,7 @@ class TestIBB(SleekTest):
iq = Iq()
iq['type'] = 'set'
iq['ibb_data']['seq'] = 0
iq['ibb_data']['data'] = 'sleekxmpp'
iq['ibb_data']['data'] = 'slixmpp'
self.check(iq, """
<iq type="set">

View File

@@ -1,11 +1,11 @@
from sleekxmpp import Iq
from slixmpp import Iq
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.plugins.xep_0050 import Command
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp.test import SlixTest
from slixmpp.plugins.xep_0050 import Command
from slixmpp.xmlstream import register_stanza_plugin
class TestAdHocCommandStanzas(SleekTest):
class TestAdHocCommandStanzas(SlixTest):
def setUp(self):
register_stanza_plugin(Iq, Command)

View File

@@ -1,10 +1,10 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.plugins.xep_0059 import Set
from sleekxmpp.xmlstream import ET
from slixmpp.test import SlixTest
from slixmpp.plugins.xep_0059 import Set
from slixmpp.xmlstream import ET
class TestSetStanzas(SleekTest):
class TestSetStanzas(SlixTest):
def testSetFirstIndex(self):
s = Set()

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.xep_0004 as xep_0004
import sleekxmpp.plugins.xep_0060.stanza as pubsub
from sleekxmpp.xmlstream.stanzabase import ET
from slixmpp.test import SlixTest
import slixmpp.plugins.xep_0004 as xep_0004
import slixmpp.plugins.xep_0060.stanza as pubsub
from slixmpp.xmlstream.stanzabase import ET
class TestPubsubStanzas(SleekTest):
class TestPubsubStanzas(SlixTest):
def testAffiliations(self):
"Testing iq/pubsub/affiliations/affiliation stanzas"
@@ -55,12 +55,12 @@ class TestPubsubStanzas(SleekTest):
iq = self.Iq()
iq['pubsub']['subscription']['suboptions']['required'] = True
iq['pubsub']['subscription']['node'] = 'testnode alsdkjfas'
iq['pubsub']['subscription']['jid'] = "fritzy@netflint.net/sleekxmpp"
iq['pubsub']['subscription']['jid'] = "fritzy@netflint.net/slixmpp"
iq['pubsub']['subscription']['subscription'] = 'unconfigured'
self.check(iq, """
<iq id="0">
<pubsub xmlns="http://jabber.org/protocol/pubsub">
<subscription node="testnode alsdkjfas" jid="fritzy@netflint.net/sleekxmpp" subscription="unconfigured">
<subscription node="testnode alsdkjfas" jid="fritzy@netflint.net/slixmpp" subscription="unconfigured">
<subscribe-options>
<required />
</subscribe-options>
@@ -157,17 +157,17 @@ class TestPubsubStanzas(SleekTest):
iq = self.Iq()
iq['pubsub']['subscribe']['options']
iq['pubsub']['subscribe']['node'] = 'cheese'
iq['pubsub']['subscribe']['jid'] = 'fritzy@netflint.net/sleekxmpp'
iq['pubsub']['subscribe']['jid'] = 'fritzy@netflint.net/slixmpp'
iq['pubsub']['subscribe']['options']['node'] = 'cheese'
iq['pubsub']['subscribe']['options']['jid'] = 'fritzy@netflint.net/sleekxmpp'
iq['pubsub']['subscribe']['options']['jid'] = 'fritzy@netflint.net/slixmpp'
form = xep_0004.Form()
form.addField('pubsub#title', ftype='text-single', value='this thing is awesome')
iq['pubsub']['subscribe']['options']['options'] = form
self.check(iq, """
<iq id="0">
<pubsub xmlns="http://jabber.org/protocol/pubsub">
<subscribe node="cheese" jid="fritzy@netflint.net/sleekxmpp">
<options node="cheese" jid="fritzy@netflint.net/sleekxmpp">
<subscribe node="cheese" jid="fritzy@netflint.net/slixmpp">
<options node="cheese" jid="fritzy@netflint.net/slixmpp">
<x xmlns="jabber:x:data" type="submit">
<field var="pubsub#title">
<value>this thing is awesome</value>

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp import Message
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.xep_0085 as xep_0085
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp import Message
from slixmpp.test import SlixTest
import slixmpp.plugins.xep_0085 as xep_0085
from slixmpp.xmlstream import register_stanza_plugin
class TestChatStates(SleekTest):
class TestChatStates(SlixTest):
def setUp(self):
register_stanza_plugin(Message, xep_0085.stanza.Active)

View File

@@ -1,11 +1,11 @@
import unittest
from sleekxmpp import Message
from sleekxmpp.test import SleekTest
import sleekxmpp.plugins.xep_0184 as xep_0184
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp import Message
from slixmpp.test import SlixTest
import slixmpp.plugins.xep_0184 as xep_0184
from slixmpp.xmlstream import register_stanza_plugin
class TestReciept(SleekTest):
class TestReciept(SlixTest):
def setUp(self):
register_stanza_plugin(Message, xep_0184.Request)

View File

@@ -1,11 +1,11 @@
# -*- coding: utf-8 -*-
from sleekxmpp.test import *
import sleekxmpp.plugins.xep_0323 as xep_0323
from slixmpp.test import *
import slixmpp.plugins.xep_0323 as xep_0323
namespace='sn'
class TestSensorDataStanzas(SleekTest):
class TestSensorDataStanzas(SlixTest):
def setUp(self):

View File

@@ -1,20 +1,20 @@
# -*- coding: utf-8 -*-
"""
SleekXMPP: The Sleek XMPP Library
Slixmpp: The Slick XMPP Library
Implementation of xeps for Internet of Things
http://wiki.xmpp.org/web/Tech_pages/IoT_systems
Copyright (C) 2013 Sustainable Innovation, Joachim.lindborg@sust.se, bjorn.westrom@consoden.se
This file is part of SleekXMPP.
This file is part of Slixmpp.
See the file LICENSE for copying permission.
"""
from sleekxmpp.test import *
import sleekxmpp.plugins.xep_0325 as xep_0325
from slixmpp.test import *
import slixmpp.plugins.xep_0325 as xep_0325
namespace='sn'
class TestControlStanzas(SleekTest):
class TestControlStanzas(SlixTest):
def setUp(self):

View File

@@ -1,9 +1,9 @@
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamTester(SleekTest):
class TestStreamTester(SlixTest):
"""
Test that we can simulate and test a stanza stream.
"""

View File

@@ -1,11 +1,11 @@
from sleekxmpp.xmlstream.matcher import MatchXPath
from sleekxmpp.xmlstream.handler import Callback
from sleekxmpp.exceptions import XMPPError
from slixmpp.xmlstream.matcher import MatchXPath
from slixmpp.xmlstream.handler import Callback
from slixmpp.exceptions import XMPPError
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamExceptions(SleekTest):
class TestStreamExceptions(SlixTest):
"""
Test handling roster updates.
"""
@@ -41,7 +41,7 @@ class TestStreamExceptions(SleekTest):
""")
def testExceptionContinueWorking(self):
"""Test that Sleek continues to respond after an XMPPError is raised."""
"""Test that Slixmpp continues to respond after an XMPPError is raised."""
def message(msg):
msg.reply()
@@ -208,7 +208,7 @@ class TestStreamExceptions(SleekTest):
<undefined-condition
xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" />
<text xmlns="urn:ietf:params:xml:ns:xmpp-stanzas">
SleekXMPP got into trouble.
Slixmpp got into trouble.
</text>
</error>
</message>
@@ -217,7 +217,7 @@ class TestStreamExceptions(SleekTest):
self.assertEqual(raised_errors, [True], "Exception was not raised: %s" % raised_errors)
def testUnknownException(self):
"""Test Sleek continues to respond after an unknown exception."""
"""Test Slixmpp continues to respond after an unknown exception."""
raised_errors = []
@@ -243,7 +243,7 @@ class TestStreamExceptions(SleekTest):
<undefined-condition
xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" />
<text xmlns="urn:ietf:params:xml:ns:xmpp-stanzas">
SleekXMPP got into trouble.
Slixmpp got into trouble.
</text>
</error>
</message>
@@ -261,7 +261,7 @@ class TestStreamExceptions(SleekTest):
<undefined-condition
xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" />
<text xmlns="urn:ietf:params:xml:ns:xmpp-stanzas">
SleekXMPP got into trouble.
Slixmpp got into trouble.
</text>
</error>
</message>

View File

@@ -1,11 +1,11 @@
import time
from sleekxmpp import Message
from slixmpp import Message
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestFilters(SleekTest):
class TestFilters(SlixTest):
"""
Test using incoming and outgoing filters.

View File

@@ -2,12 +2,12 @@ import time
import threading
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.exceptions import IqTimeout
from sleekxmpp import Callback, MatchXPath
from slixmpp.test import SlixTest
from slixmpp.exceptions import IqTimeout
from slixmpp import Callback, MatchXPath
class TestHandlers(SleekTest):
class TestHandlers(SlixTest):
"""
Test using handlers and waiters.
"""
@@ -239,7 +239,7 @@ class TestHandlers(SleekTest):
# Check that Iq was sent by waiter_handler
iq = self.Iq()
iq['id'] = 'test'
iq['to'] = 'tester@sleekxmpp.com/test'
iq['to'] = 'tester@slixmpp.com/test'
iq['type'] = 'set'
iq['query'] = 'test'
result = iq.send()
@@ -249,12 +249,12 @@ class TestHandlers(SleekTest):
t.start()
self.recv("""
<iq id="test" from="evil@sleekxmpp.com/bad" type="result">
<iq id="test" from="evil@slixmpp.com/bad" type="result">
<query xmlns="test" />
</iq>
""")
self.recv("""
<iq id="test" from="evil2@sleekxmpp.com" type="result">
<iq id="test" from="evil2@slixmpp.com" type="result">
<query xmlns="test" />
</iq>
""")
@@ -266,7 +266,7 @@ class TestHandlers(SleekTest):
# Now for a good one
self.recv("""
<iq id="test" from="tester@sleekxmpp.com/test" type="result">
<iq id="test" from="tester@slixmpp.com/test" type="result">
<query xmlns="test" />
</iq>
""")
@@ -275,7 +275,7 @@ class TestHandlers(SleekTest):
time.sleep(0.1)
self.assertEqual(events, ['tester@sleekxmpp.com/test'], "Did not timeout on bad sender")
self.assertEqual(events, ['tester@slixmpp.com/test'], "Did not timeout on bad sender")

View File

@@ -1,9 +1,9 @@
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamPresence(SleekTest):
class TestStreamPresence(SlixTest):
"""
Test handling roster updates.
"""

View File

@@ -2,13 +2,13 @@
from __future__ import unicode_literals
import unittest
from sleekxmpp.exceptions import IqTimeout
from sleekxmpp.test import SleekTest
from slixmpp.exceptions import IqTimeout
from slixmpp.test import SlixTest
import time
import threading
class TestStreamRoster(SleekTest):
class TestStreamRoster(SlixTest):
"""
Test handling roster updates.
"""

View File

@@ -2,10 +2,10 @@ import time
import threading
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamDisco(SleekTest):
class TestStreamDisco(SlixTest):
"""
Test using the XEP-0030 plugin.

View File

@@ -2,10 +2,10 @@ import threading
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestInBandByteStreams(SleekTest):
class TestInBandByteStreams(SlixTest):
def setUp(self):
self.stream_start(plugins=['xep_0047', 'xep_0030'])

View File

@@ -2,11 +2,11 @@ import time
import logging
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream import ElementBase, register_stanza_plugin
from slixmpp.test import SlixTest
from slixmpp.xmlstream import ElementBase, register_stanza_plugin
class TestAdHocCommands(SleekTest):
class TestAdHocCommands(SlixTest):
def setUp(self):
self.stream_start(mode='client',

View File

@@ -1,13 +1,13 @@
import threading
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream import register_stanza_plugin
from sleekxmpp.plugins.xep_0030 import DiscoItems
from sleekxmpp.plugins.xep_0059 import ResultIterator, Set
from slixmpp.test import SlixTest
from slixmpp.xmlstream import register_stanza_plugin
from slixmpp.plugins.xep_0030 import DiscoItems
from slixmpp.plugins.xep_0059 import ResultIterator, Set
class TestStreamSet(SleekTest):
class TestStreamSet(SlixTest):
def setUp(self):
register_stanza_plugin(DiscoItems, Set)

View File

@@ -1,12 +1,12 @@
import threading
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.stanza.atom import AtomEntry
from sleekxmpp.xmlstream import register_stanza_plugin
from slixmpp.test import SlixTest
from slixmpp.stanza.atom import AtomEntry
from slixmpp.xmlstream import register_stanza_plugin
class TestStreamPubsub(SleekTest):
class TestStreamPubsub(SlixTest):
"""
Test using the XEP-0030 plugin.

View File

@@ -1,10 +1,10 @@
import threading
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestOOB(SleekTest):
class TestOOB(SlixTest):
def tearDown(self):
self.stream_close()
@@ -13,21 +13,21 @@ class TestOOB(SleekTest):
"""Test sending an OOB transfer request."""
self.stream_start(plugins=['xep_0066', 'xep_0030'])
url = 'http://github.com/fritzy/SleekXMPP/blob/master/README'
url = 'http://github.com/fritzy/Slixmpp/blob/master/README'
t = threading.Thread(
name='send_oob',
target=self.xmpp['xep_0066'].send_oob,
args=('user@example.com', url),
kwargs={'desc': 'SleekXMPP README'})
kwargs={'desc': 'Slixmpp README'})
t.start()
self.send("""
<iq to="user@example.com" type="set" id="1">
<query xmlns="jabber:iq:oob">
<url>http://github.com/fritzy/SleekXMPP/blob/master/README</url>
<desc>SleekXMPP README</desc>
<url>http://github.com/fritzy/Slixmpp/blob/master/README</url>
<desc>Slixmpp README</desc>
</query>
</iq>
""")

View File

@@ -1,10 +1,10 @@
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamChatStates(SleekTest):
class TestStreamChatStates(SlixTest):
def tearDown(self):
self.stream_close()

View File

@@ -1,10 +1,10 @@
import threading
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamSet(SleekTest):
class TestStreamSet(SlixTest):
def tearDown(self):
self.stream_close()
@@ -12,7 +12,7 @@ class TestStreamSet(SleekTest):
def testHandleSoftwareVersionRequest(self):
self.stream_start(mode='client', plugins=['xep_0030', 'xep_0092'])
self.xmpp['xep_0092'].name = 'SleekXMPP'
self.xmpp['xep_0092'].name = 'Slixmpp'
self.xmpp['xep_0092'].version = 'dev'
self.xmpp['xep_0092'].os = 'Linux'
@@ -25,7 +25,7 @@ class TestStreamSet(SleekTest):
self.send("""
<iq type="result" id="1">
<query xmlns="jabber:iq:version">
<name>SleekXMPP</name>
<name>Slixmpp</name>
<version>dev</version>
<os>Linux</os>
</query>

View File

@@ -1,8 +1,8 @@
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamExtendedDisco(SleekTest):
class TestStreamExtendedDisco(SlixTest):
"""
Test using the XEP-0128 plugin.

View File

@@ -1,10 +1,10 @@
import time
import unittest
from sleekxmpp.test import SleekTest
from slixmpp.test import SlixTest
class TestStreamDirectInvite(SleekTest):
class TestStreamDirectInvite(SlixTest):
"""
Test using the XEP-0249 plugin.
@@ -47,13 +47,13 @@ class TestStreamDirectInvite(SleekTest):
self.xmpp['xep_0249'].send_invitation('user@example.com',
'sleek@conference.jabber.org',
reason='Need to test Sleek')
reason='Need to test Slixmpp')
self.send("""
<message to="user@example.com">
<x xmlns="jabber:x:conference"
jid="sleek@conference.jabber.org"
reason="Need to test Sleek" />
reason="Need to test Slixmpp" />
</message>
""")

View File

@@ -5,12 +5,12 @@ import datetime
import time
import threading
from sleekxmpp.test import *
from sleekxmpp.xmlstream import ElementBase
from sleekxmpp.plugins.xep_0323.device import Device
from slixmpp.test import *
from slixmpp.xmlstream import ElementBase
from slixmpp.plugins.xep_0323.device import Device
class TestStreamSensorData(SleekTest):
class TestStreamSensorData(SlixTest):
"""
Test using the XEP-0323 plugin.

View File

@@ -1,10 +1,10 @@
# -*- coding: utf-8 -*-
"""
SleekXMPP: The Sleek XMPP Library
Slixmpp: The Slick XMPP Library
Implementation of xeps for Internet of Things
http://wiki.xmpp.org/web/Tech_pages/IoT_systems
Copyright (C) 2013 Sustainable Innovation, Joachim.lindborg@sust.se, bjorn.westrom@consoden.se
This file is part of SleekXMPP.
This file is part of Slixmpp.
See the file LICENSE for copying permission.
"""
@@ -14,12 +14,12 @@ import datetime
import time
import threading
from sleekxmpp.test import *
from sleekxmpp.xmlstream import ElementBase
from sleekxmpp.plugins.xep_0325.device import Device
from slixmpp.test import *
from slixmpp.xmlstream import ElementBase
from slixmpp.plugins.xep_0325.device import Device
class TestStreamControl(SleekTest):
class TestStreamControl(SlixTest):
"""
Test using the XEP-0325 plugin.

View File

@@ -1,13 +1,13 @@
import unittest
from sleekxmpp.test import SleekTest
from sleekxmpp.xmlstream.stanzabase import ET
from sleekxmpp.xmlstream.tostring import tostring, escape
from slixmpp.test import SlixTest
from slixmpp.xmlstream.stanzabase import ET
from slixmpp.xmlstream.tostring import tostring, escape
class TestToString(SleekTest):
class TestToString(SlixTest):
"""
Test the implementation of sleekxmpp.xmlstream.tostring
Test the implementation of slixmpp.xmlstream.tostring
"""
def tearDown(self):