From c0418fde1b21158b65c5935b768725eeb2829649 Mon Sep 17 00:00:00 2001
From: Rafael Monnerat <rafael@nexedi.com>
Date: Fri, 28 May 2010 21:48:23 +0000
Subject: [PATCH] It is too frequently that the ERP5Type product are not into
 the instance (ie. Like in buildout), so it should be possible for developer
 define a specific 'REAL_INSTANCE_HOME' using environment. This allows
 developer create diferent testrunners quite easily, in case they share same
 Products.

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

diff --git a/product/ERP5Type/tests/runUnitTest.py b/product/ERP5Type/tests/runUnitTest.py
index 25018485bb..9a14b5e500 100755
--- a/product/ERP5Type/tests/runUnitTest.py
+++ b/product/ERP5Type/tests/runUnitTest.py
@@ -250,6 +250,10 @@ elif tests_framework_home.startswith('/usr/lib'):
     real_instance_home = '/var/lib/erp5'
   else:
     real_instance_home = '/var/lib/zope'
+elif os.environ.get('REAL_INSTANCE_HOME', None) is not None:
+  # The user Defined where is the REAL INSTANCE HOME
+  # So we should use it
+  real_instance_home = os.environ.get('REAL_INSTANCE_HOME')
 else:
   real_instance_home = os.path.sep.join(
       tests_framework_home.split(os.path.sep)[:-3])
-- 
2.30.9