From e4b5cdd152ad31bd17daa0b60752f46f00591fcd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com>
Date: Fri, 4 Aug 2006 08:45:00 +0000
Subject: [PATCH] fix indentation keep a reference of Globals.get_request
 before monkey patching it

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@9042 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5Type/tests/ERP5TypeTestCase.py | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/product/ERP5Type/tests/ERP5TypeTestCase.py b/product/ERP5Type/tests/ERP5TypeTestCase.py
index 9274b95590..154d9a8ae1 100644
--- a/product/ERP5Type/tests/ERP5TypeTestCase.py
+++ b/product/ERP5Type/tests/ERP5TypeTestCase.py
@@ -10,6 +10,8 @@ __version__ = '0.3.0'
 current_app = None
 import Products.ERP5Type.Utils
 import Globals
+# store a copy of the original method
+original_get_request = Globals.get_request
 
 def get_request():
   return current_app.REQUEST
@@ -159,10 +161,10 @@ class ERP5TypeTestCase(PortalTestCase):
       return portal_name + '_' + uid
 
     def getPortal(self):
-        """Returns the portal object, i.e. the "fixture root".
-           Override if you don't like the default.
-        """
-        return self.app[self.getPortalName()]
+      """Returns the portal object, i.e. the "fixture root".
+         Override if you don't like the default.
+      """
+      return self.app[self.getPortalName()]
 
     def enableLightInstall(self):
       """
-- 
2.30.9