changeset 8:a07bf3fb4b54

core (tests): test fixes
author Goffi <goffi@goffi.org>
date Thu, 23 Apr 2015 14:19:43 +0200
parents 1e21b4e94566
children 9a4c367b22bb
files wokkel/delay.py wokkel/mam.py wokkel/pubsub.py wokkel/rsm.py
diffstat 4 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/wokkel/delay.py	Thu Apr 23 13:35:21 2015 +0200
+++ b/wokkel/delay.py	Thu Apr 23 14:19:43 2015 +0200
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 # -*- test-case-name: wokkel.test.test_delay -*-
 #
 # SàT adaptation for wokkel.delay
--- a/wokkel/mam.py	Thu Apr 23 13:35:21 2015 +0200
+++ b/wokkel/mam.py	Thu Apr 23 14:19:43 2015 +0200
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 # -*- test-case-name: wokkel.test.test_mam -*-
 #
 # SàT Wokkel extension for Message Archive Management (XEP-0313)
@@ -157,8 +158,9 @@
     @type never: C{list}
     """
 
-    def __init__(self, default, always=None, never=None):
-        assert default in ('always', 'never', 'roster')
+    def __init__(self, default=None, always=None, never=None):
+        if default is not None:
+            assert default in ('always', 'never', 'roster')
         self.default = default
         if always is not None:
             assert isinstance(always, list)
--- a/wokkel/pubsub.py	Thu Apr 23 13:35:21 2015 +0200
+++ b/wokkel/pubsub.py	Thu Apr 23 14:19:43 2015 +0200
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 # -*- test-case-name: wokkel.test.test_pubsub -*-
 #
 # SàT adaptation for wokkel.pubsub
@@ -1256,7 +1257,7 @@
             if request is None:
                 return defer.succeed(None)
 
-        # Process the request itself, 
+        # Process the request itself,
         if resource is not self:
             try:
                 handler = getattr(resource, request.verb)
--- a/wokkel/rsm.py	Thu Apr 23 13:35:21 2015 +0200
+++ b/wokkel/rsm.py	Thu Apr 23 14:19:43 2015 +0200
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 # -*- test-case-name: wokkel.test.test_rsm -*-
 #
 # SàT Wokkel extension for Result Set Management (XEP-0059)