Changeset 5735 for main/waeup.sirp/trunk/src/waeup/sirp/utils/tests
- Timestamp:
- 12 Feb 2011, 14:42:42 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/utils/tests/test_helpers.py
r5733 r5735 24 24 from waeup.sirp.utils import helpers 25 25 26 from zope.interface import Interface, implements 27 class IFakeObject(Interface): 28 """Some marker interface.""" 29 30 class FakeObject(object): 31 implements(IFakeObject) 32 33 class FactoryBaseTestCase(unittest.TestCase): 34 35 def test_ifaces(self): 36 # We test all relevant parts in the docstring. But the interfaces 37 # method has to be tested to please the coverage report as well. 38 factory = helpers.FactoryBase() 39 factory.factory = FakeObject 40 self.assertTrue(factory.getInterfaces()(IFakeObject)) 41 return 42 26 43 def test_suite(): 27 44 suite = unittest.TestSuite() 45 # Register local test cases... 46 for testcase in [FactoryBaseTestCase, ]: 47 suite.addTests( 48 unittest.TestLoader().loadTestsFromTestCase(testcase) 49 ) 50 # Add tests from docstrings in helpers.py... 28 51 suite.addTests( 29 52 doctest.DocTestSuite(
Note: See TracChangeset for help on using the changeset viewer.