Back to index

plone3  3.1.7
test_vocabularies.py
Go to the documentation of this file.
00001 import unittest
00002 
00003 import zope.component
00004 from zope.component.testing import setUp, tearDown
00005 from zope.configuration.xmlconfig import XMLConfig
00006 from zope.testing import doctest
00007 from zope.testing.doctestunit import DocTestSuite
00008 
00009 import plone.app.vocabularies
00010 
00011 def configurationSetUp(self):
00012     setUp()
00013     XMLConfig('meta.zcml', zope.component)()
00014     XMLConfig('configure.zcml', plone.app.vocabularies)()
00015 
00016 
00017 def test_suite():
00018     return unittest.TestSuite((
00019         DocTestSuite('plone.app.vocabularies.catalog',
00020                      setUp=configurationSetUp,
00021                      tearDown=tearDown,
00022                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00023         DocTestSuite('plone.app.vocabularies.groups',
00024                      setUp=configurationSetUp,
00025                      tearDown=tearDown,
00026                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00027         DocTestSuite('plone.app.vocabularies.language',
00028                      setUp=configurationSetUp,
00029                      tearDown=tearDown,
00030                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00031         DocTestSuite('plone.app.vocabularies.security',
00032                      setUp=configurationSetUp,
00033                      tearDown=tearDown,
00034                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00035         DocTestSuite('plone.app.vocabularies.skins',
00036                      setUp=configurationSetUp,
00037                      tearDown=tearDown,
00038                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00039         DocTestSuite('plone.app.vocabularies.terms'),
00040         DocTestSuite('plone.app.vocabularies.types',
00041                      setUp=configurationSetUp,
00042                      tearDown=tearDown,
00043                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00044         DocTestSuite('plone.app.vocabularies.users',
00045                      setUp=configurationSetUp,
00046                      tearDown=tearDown,
00047                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00048         DocTestSuite('plone.app.vocabularies.workflow',
00049                      setUp=configurationSetUp,
00050                      tearDown=tearDown,
00051                      optionflags=doctest.ELLIPSIS | doctest.NORMALIZE_WHITESPACE),
00052         ))
00053 
00054 if __name__ == '__main__':
00055     unittest.main(defaultTest='test_suite')