Back to index

plone3  3.1.7
test_setup.py
Go to the documentation of this file.
00001 from zope.lifecycleevent.interfaces import IObjectModifiedEvent
00002 from zope.app.container.interfaces import IObjectAddedEvent
00003 from zope.app.container.interfaces import IObjectRemovedEvent
00004 
00005 from plone.contentrules.engine.interfaces import IRuleAssignable
00006 from plone.contentrules.rule.interfaces import IRuleEventType
00007 
00008 from plone.app.contentrules.tests.base import ContentRulesTestCase
00009 
00010 class TestProductInstall(ContentRulesTestCase):
00011 
00012     def testRuleContainerInterfaces(self): 
00013         self.failUnless(IRuleAssignable.providedBy(self.folder))
00014         self.failUnless(IRuleAssignable.providedBy(self.portal))
00015         
00016     def testEventTypesMarked(self): 
00017         self.failUnless(IRuleEventType.providedBy(IObjectAddedEvent))
00018         self.failUnless(IRuleEventType.providedBy(IObjectModifiedEvent))
00019         self.failUnless(IRuleEventType.providedBy(IObjectRemovedEvent))
00020         
00021 def test_suite():
00022     from unittest import TestSuite, makeSuite
00023     suite = TestSuite()
00024     suite.addTest(makeSuite(TestProductInstall))
00025     return suite