[Zope3-checkins] CVS: Zope3/src/zope/app/renderer/tests - test_stx.py:1.2

Philipp von Weitershausen philikon at philikon.de
Thu Feb 19 14:56:53 EST 2004


Update of /cvs-repository/Zope3/src/zope/app/renderer/tests
In directory cvs.zope.org:/tmp/cvs-serv4712/tests

Modified Files:
	test_stx.py 
Log Message:
Enable structured text rendering (incl. unit tests) now that we have
zope.structuredtext.


=== Zope3/src/zope/app/renderer/tests/test_stx.py 1.1 => 1.2 ===
--- Zope3/src/zope/app/renderer/tests/test_stx.py:1.1	Thu Jul 31 13:59:41 2003
+++ Zope3/src/zope/app/renderer/tests/test_stx.py	Thu Feb 19 14:56:53 2004
@@ -19,13 +19,8 @@
 
 from zope.publisher.browser import TestRequest
 
-try:
-    from zope.app.interfaces.renderer import \
-         IStructuredTextSource, IHTMLRenderer
-    from zope.app.renderer.stx import \
-         StructuredTextSource, StructuredTextToHTMLRenderer
-except ImportError:
-    pass
+from zope.app.interfaces.renderer import IStructuredTextSource, IHTMLRenderer
+from zope.app.renderer.stx import StructuredTextSource, StructuredTextToHTMLRenderer
 
 class StructuredTextTest(unittest.TestCase):
 
@@ -63,7 +58,6 @@
                                              'srichter',
                                              '04/12/2003 12:00:00')
         self._renderer.context = StructuredTextSource(self._source+comment)
-
         self.assertEqual(rendered_source_comment, self._renderer.render(None))
         
 
@@ -90,13 +84,8 @@
     
 def test_suite():
     suite = unittest.TestSuite()
-    try:
-        import StructuredText
-    except ImportError:
-        pass
-    else:
-        suite.addTest(unittest.makeSuite(StructuredTextTest))
-        suite.addTest(unittest.makeSuite(HTMLRendererTest))
+    suite.addTest(unittest.makeSuite(StructuredTextTest))
+    suite.addTest(unittest.makeSuite(HTMLRendererTest))
     return suite
 
 if __name__ == '__main__':




More information about the Zope3-Checkins mailing list