[Zope3-checkins] CVS: Zope3/src/zope/app/onlinehelp/tests - test_onlinehelp.py:1.2 test_onlinehelptopic.py:1.2

Roger Ineichen roger@projekt01.ch
Tue, 24 Jun 2003 05:56:11 -0400


Update of /cvs-repository/Zope3/src/zope/app/onlinehelp/tests
In directory cvs.zope.org:/tmp/cvs-serv30225

Modified Files:
	test_onlinehelp.py test_onlinehelptopic.py 
Log Message:
Added interface tests for onlinehelp.

=== Zope3/src/zope/app/onlinehelp/tests/test_onlinehelp.py 1.1 => 1.2 ===
--- Zope3/src/zope/app/onlinehelp/tests/test_onlinehelp.py:1.1	Tue Jan  7 07:27:52 2003
+++ Zope3/src/zope/app/onlinehelp/tests/test_onlinehelp.py	Tue Jun 24 05:56:10 2003
@@ -18,7 +18,10 @@
 import os
 from unittest import TestSuite, makeSuite
 from zope.interface import Interface
+from zope.interface.verify import verifyObject
 from zope.app.onlinehelp import OnlineHelp
+from zope.app.interfaces.onlinehelp import IOnlineHelp
+from zope.app.interfaces.traversing import IContainmentRoot
 from test_onlinehelptopic import TestOnlineHelpTopic, testdir
 
 class I1(Interface):
@@ -52,6 +55,11 @@
         self.assertEqual(
             self.topic.getTopicsForInterfaceAndView(I1, View)[0].title,
             'Help 2')
+            
+    def test_interface(self):
+        verifyObject(IOnlineHelp, self.topic)
+        verifyObject(IContainmentRoot, self.topic)
+
 
 def test_suite():
     return TestSuite((


=== Zope3/src/zope/app/onlinehelp/tests/test_onlinehelptopic.py 1.1 => 1.2 ===
--- Zope3/src/zope/app/onlinehelp/tests/test_onlinehelptopic.py:1.1	Tue Jan  7 07:27:52 2003
+++ Zope3/src/zope/app/onlinehelp/tests/test_onlinehelptopic.py	Tue Jun 24 05:56:10 2003
@@ -17,7 +17,9 @@
 """
 import os
 from unittest import TestCase, TestSuite, makeSuite
+from zope.interface.verify import verifyObject
 from zope.app.onlinehelp import OnlineHelpTopic
+from zope.app.interfaces.onlinehelp import IOnlineHelpTopic
 
 def testdir():
     import zope.app.onlinehelp.tests
@@ -46,6 +48,10 @@
         self.topic.setContentPath(path, 'foo')
         self.assertEqual(self.topic.getContent(),
                          'This is a help!')
+                         
+    def test_interface(self):
+        verifyObject(IOnlineHelpTopic, self.topic)
+              
 
 def test_suite():
     return TestSuite((