[Zope3-checkins] CVS: Zope3/src/zope/publisher - browser.py:1.22

Jim Fulton cvs-admin at zope.org
Fri Nov 21 12:12:35 EST 2003


Update of /cvs-repository/Zope3/src/zope/publisher
In directory cvs.zope.org:/tmp/cvs-serv364/src/zope/publisher

Modified Files:
	browser.py 
Log Message:
Added the ability to specify a skin to the test request.


=== Zope3/src/zope/publisher/browser.py 1.21 => 1.22 ===
--- Zope3/src/zope/publisher/browser.py:1.21	Mon Nov  3 16:37:50 2003
+++ Zope3/src/zope/publisher/browser.py	Fri Nov 21 12:12:34 2003
@@ -23,7 +23,6 @@
 from zope.interface import implements
 from zope.i18n.interfaces import IUserPreferredLanguages
 from zope.i18n.interfaces import IUserPreferredCharsets
-from zope.publisher.interfaces.browser import IBrowserPresentation
 from zope.publisher.interfaces.browser import IBrowserRequest
 from zope.publisher.interfaces.browser import IBrowserApplicationRequest
 
@@ -237,11 +236,6 @@
     use_redirect = 0 # Set this to 1 in a subclass to redirect GET
                      # requests when the effective and actual URLs differ.
 
-    # _presentation_type is overridden from the BaseRequest
-    #  to implement IBrowserPresentation
-    _presentation_type = IBrowserPresentation
-
-
 
     def __init__(self, body_instream, outstream, environ, response=None):
         self.form = {}
@@ -711,6 +705,7 @@
 
     def __init__(self,
                  body_instream=None, outstream=None, environ=None, form=None,
+                 skin='default',
                  **kw):
 
         _testEnv =  {
@@ -735,6 +730,8 @@
         super(TestRequest, self).__init__(body_instream, outstream, _testEnv)
         if form:
             self.form.update(form)
+
+        self.setPresentationSkin(skin)
 
     def setUser(self, user):
         # HTTPRequest needs to notify the HTTPTask of the username.




More information about the Zope3-Checkins mailing list