Log message for revision 69055: added dedicated tests for 'file' and 'url' options
Changed: U Zope/trunk/lib/python/Products/ZReST/tests/test_ZReST.py -=- Modified: Zope/trunk/lib/python/Products/ZReST/tests/test_ZReST.py =================================================================== --- Zope/trunk/lib/python/Products/ZReST/tests/test_ZReST.py 2006-07-09 07:47:47 UTC (rev 69054) +++ Zope/trunk/lib/python/Products/ZReST/tests/test_ZReST.py 2006-07-09 09:35:23 UTC (rev 69055) @@ -69,13 +69,22 @@ resty.source = 'hello world\n .. include:: /etc/passwd' self.assertRaises(NotImplementedError, resty.render) -# disabled test so far until we have a consensus how to deal with 'raw' -# def testRawPassthrough(self): -# resty = self._makeOne() -# resty.source = '.. raw:: html\n\n <h1>HELLO WORLD</h1>' -# self.assertRaises(NotImplementedError, resty.render) + def testRawPassthrough(self): + resty = self._makeOne() + resty.source = '.. raw:: html\n <h1>HELLO WORLD</h1>' + result = resty.render() # should not fail + + resty = self._makeOne() + resty.source = '.. raw:: html\n :file: inclusion.txt' + self.assertRaises(NotImplementedError, resty.render) + + resty = self._makeOne() + resty.source = '.. raw:: html\n :url: http://www.zope.org/' + self.assertRaises(NotImplementedError, resty.render) + + def test_suite(): suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(TestZReST)) _______________________________________________ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins