[Checkins] SVN: zope.app.locales/trunk/ - Using Python's ``doctest`` module instead of depreacted ``zope.testing.doctest``.

Michael Howitz mh at gocept.com
Sat Sep 25 11:51:46 EDT 2010


Log message for revision 116934:
  - Using Python's ``doctest`` module instead of depreacted ``zope.testing.doctest``.
  

Changed:
  U   zope.app.locales/trunk/CHANGES.txt
  U   zope.app.locales/trunk/src/zope/app/locales/tests.py

-=-
Modified: zope.app.locales/trunk/CHANGES.txt
===================================================================
--- zope.app.locales/trunk/CHANGES.txt	2010-09-25 15:42:36 UTC (rev 116933)
+++ zope.app.locales/trunk/CHANGES.txt	2010-09-25 15:51:45 UTC (rev 116934)
@@ -5,9 +5,9 @@
 3.6.3 (unreleased)
 ------------------
 
-- Nothing changed yet.
+- Using Python's ``doctest`` module instead of depreacted
+  ``zope.testing.doctest``.
 
-
 3.6.2 (2010-07-31)
 ------------------
 

Modified: zope.app.locales/trunk/src/zope/app/locales/tests.py
===================================================================
--- zope.app.locales/trunk/src/zope/app/locales/tests.py	2010-09-25 15:42:36 UTC (rev 116933)
+++ zope.app.locales/trunk/src/zope/app/locales/tests.py	2010-09-25 15:51:45 UTC (rev 116934)
@@ -11,21 +11,19 @@
 # FOR A PARTICULAR PURPOSE.
 #
 ##############################################################################
-"""Tests for the message string extraction tool.
+"""Tests for the message string extraction tool."""
 
-$Id$
-"""
 import os
 import doctest
 import unittest
-from zope.testing.doctest import DocTestSuite
 
+
 class TestIsUnicodeInAllCatalog(unittest.TestCase):
     """
     """
     def setUp(self):
         pass
-    
+
     def test_is_unicode(self):
         from zope.i18n.gettextmessagecatalog import GettextMessageCatalog
         path = os.path.dirname(__file__)
@@ -39,16 +37,16 @@
                         mcatalog = GettextMessageCatalog(lang, 'zope',
                                            os.path.join(lc_path, f))
                         catalog = mcatalog._catalog
-                        self.failUnless(catalog._charset, 
-            u"""Charset value for the Message catalog is missing. 
-                The language is %s (zope.po). 
+                        self.failUnless(catalog._charset,
+            u"""Charset value for the Message catalog is missing.
+                The language is %s (zope.po).
                 Value of the message catalog should be in unicode""" % (lang,)
                                         )
 
 
 def test_suite():
     return unittest.TestSuite((
-        DocTestSuite('zope.app.locales.extract',
+        doctest.DocTestSuite('zope.app.locales.extract',
             optionflags=doctest.NORMALIZE_WHITESPACE|doctest.ELLIPSIS,),
         unittest.makeSuite(TestIsUnicodeInAllCatalog),
         ))



More information about the checkins mailing list