[Zope3-checkins] SVN: Zope3/trunk/src/zope/publisher/tests/basetestipublicationrequest.py The presentation service is gone.

Stephan Richter srichter at cosmos.phy.tufts.edu
Fri Sep 17 12:16:36 EDT 2004


Log message for revision 27596:
  
  The presentation service is gone.
  
  Updated test to the new way skins are set.
  
  


Changed:
  U   Zope3/trunk/src/zope/publisher/tests/basetestipublicationrequest.py


-=-
Modified: Zope3/trunk/src/zope/publisher/tests/basetestipublicationrequest.py
===================================================================
--- Zope3/trunk/src/zope/publisher/tests/basetestipublicationrequest.py	2004-09-17 16:16:34 UTC (rev 27595)
+++ Zope3/trunk/src/zope/publisher/tests/basetestipublicationrequest.py	2004-09-17 16:16:35 UTC (rev 27596)
@@ -15,10 +15,12 @@
 
 $Id$
 """
+import sys
 
-import sys
+from zope.interface import Interface, directlyProvides
 from zope.interface.verify import verifyObject
 from zope.publisher.interfaces import IPublicationRequest
+from zope.publisher.interfaces.browser import ISkin
 
 
 class BaseTestIPublicationRequest(object):
@@ -54,8 +56,12 @@
 
     def testSkinManagement(self):
         request = self._Test__new()
-        self.assertEqual(request.getPresentationSkin(), '')
-        skin = 'terse'
-        request.setPresentationSkin(skin)
-        self.assertEqual(request.getPresentationSkin(), skin)
 
+        class IMoreFoo(Interface):
+            pass
+        directlyProvides(IMoreFoo, ISkin)
+
+        self.assertEqual(IMoreFoo.providedBy(request), False)
+        directlyProvides(request, IMoreFoo)
+        self.assertEqual(IMoreFoo.providedBy(request), True)
+



More information about the Zope3-Checkins mailing list