Back to index

plone3  3.1.7
test_setup.py
Go to the documentation of this file.
00001 import unittest
00002 from plone.app.redirector.tests.base import RedirectorTestCase
00003 
00004 from zope.component import queryUtility
00005 
00006 from plone.app.redirector.interfaces import IRedirectionStorage
00007 
00008 class TestRedirectorSetup(RedirectorTestCase):
00009     """Ensure that the basic redirector setup is successful.
00010     """
00011 
00012     def test_utility(self):
00013         utility = queryUtility(IRedirectionStorage)
00014         self.assertNotEquals(None, utility)
00015 
00016     def test_view(self):
00017         view = self.portal.restrictedTraverse('@@plone_redirector_view')
00018         self.assertNotEquals(None, view)
00019 
00020 def test_suite():
00021     suite = unittest.TestSuite()
00022     suite.addTest(unittest.makeSuite(TestRedirectorSetup))
00023     return suite