[Zope3-checkins] SVN: Zope3/trunk/src/zope/server/http/tests/test_publisherserver.py Raising a string exception is deprecated

Dmitry Vasiliev dima at hlabs.spb.ru
Thu May 19 04:28:33 EDT 2005


Log message for revision 30411:
  Raising a string exception is deprecated
  

Changed:
  U   Zope3/trunk/src/zope/server/http/tests/test_publisherserver.py

-=-
Modified: Zope3/trunk/src/zope/server/http/tests/test_publisherserver.py
===================================================================
--- Zope3/trunk/src/zope/server/http/tests/test_publisherserver.py	2005-05-19 07:00:58 UTC (rev 30410)
+++ Zope3/trunk/src/zope/server/http/tests/test_publisherserver.py	2005-05-19 08:28:32 UTC (rev 30411)
@@ -59,6 +59,8 @@
             DefaultPublication.handleException(self, object, request, exc_info,
                                                retry_allowed)
 
+class Accepted(Exception):
+    pass
 
 class tested_object(object):
     """Docstring required by publisher."""
@@ -80,7 +82,7 @@
         Returns 202 status only after (wait_tries) tries.
         """
         if self.tries >= int(wait_tries):
-            raise "Accepted"
+            raise Accepted
         else:
             self.tries += 1
             raise Conflict



More information about the Zope3-Checkins mailing list