[Checkins] SVN: zc.zope3recipes/trunk/ Merge from the 0.6 branch:
Christophe Combelles
ccomb at free.fr
Wed Aug 13 18:31:19 EDT 2008
Log message for revision 89815:
Merge from the 0.6 branch:
added newest=false to prevent upgrades during tests
Changed:
U zc.zope3recipes/trunk/README.txt
U zc.zope3recipes/trunk/zc/zope3recipes/README.txt
U zc.zope3recipes/trunk/zc/zope3recipes/tests.py
-=-
Modified: zc.zope3recipes/trunk/README.txt
===================================================================
--- zc.zope3recipes/trunk/README.txt 2008-08-13 22:27:06 UTC (rev 89814)
+++ zc.zope3recipes/trunk/README.txt 2008-08-13 22:31:19 UTC (rev 89815)
@@ -16,7 +16,12 @@
Releases
********
+=====================
+0.6.2dev (unreleased)
+=====================
+Added the "newest=false" option in the SetUp to prevent upgrade during tests
+
==================
0.7.0 (2008/02/01)
==================
Modified: zc.zope3recipes/trunk/zc/zope3recipes/README.txt
===================================================================
--- zc.zope3recipes/trunk/zc/zope3recipes/README.txt 2008-08-13 22:27:06 UTC (rev 89814)
+++ zc.zope3recipes/trunk/zc/zope3recipes/README.txt 2008-08-13 22:31:19 UTC (rev 89815)
@@ -46,6 +46,8 @@
... setup(name = 'demo2', install_requires='demo1')
... ''')
+.. Please note that the "newest=false" option is set in the test SetUp to prevent upgrades
+
We'll create a buildout.cfg file that defines our application:
>>> write('buildout.cfg',
Modified: zc.zope3recipes/trunk/zc/zope3recipes/tests.py
===================================================================
--- zc.zope3recipes/trunk/zc/zope3recipes/tests.py 2008-08-13 22:27:06 UTC (rev 89814)
+++ zc.zope3recipes/trunk/zc/zope3recipes/tests.py 2008-08-13 22:31:19 UTC (rev 89815)
@@ -195,6 +195,21 @@
zc.buildout.testing.install('zdaemon', test)
zc.buildout.testing.install('ZConfig', test)
zc.buildout.testing.install('zc.recipe.filestorage', test)
+ # prevent upgrade during test
+ if not os.path.exists(os.environ['HOME']):
+ os.mkdir(os.environ['HOME'])
+ buildout_defaults_dir = os.path.join(os.environ['HOME'],
+ '.buildout')
+ buildout_defaults_file = os.path.join(buildout_defaults_dir,
+ 'default.cfg')
+ if not os.path.exists(buildout_defaults_dir):
+ os.mkdir(buildout_defaults_dir)
+ if not os.path.exists(buildout_defaults_file):
+ open(buildout_defaults_file, 'w').write(
+ "[buildout]\n"
+ "newest = false")
+ else:
+ raise RuntimeWarning('Unable to set "newest=false" for tests')
checker = renormalizing.RENormalizing([
More information about the Checkins
mailing list