[Checkins] SVN: zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/ make the tests pass with more versions of buildout
Fred Drake
cvs-admin at zope.org
Tue Mar 26 17:44:32 UTC 2013
Log message for revision 130165:
make the tests pass with more versions of buildout
Changed:
U zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/README.txt
U zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/tests.py
-=-
Modified: zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/README.txt
===================================================================
--- zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/README.txt 2013-03-22 15:10:18 UTC (rev 130164)
+++ zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/README.txt 2013-03-26 17:44:30 UTC (rev 130165)
@@ -72,10 +72,10 @@
import zdaemon.zdctl
<BLANKLINE>
if __name__ == '__main__':
- zdaemon.zdctl.main([
+ sys.exit(zdaemon.zdctl.main([
'-C', '/sample-buildout/parts/run/zdaemon.conf',
]+sys.argv[1:]
- )
+ ))
zdaemon will also be installed:
@@ -157,10 +157,10 @@
import zdaemon.zdctl
<BLANKLINE>
if __name__ == '__main__':
- zdaemon.zdctl.main([
+ sys.exit(zdaemon.zdctl.main([
'-C', 'etc/run-zdaemon.conf',
]+sys.argv[1:]
- )
+ ))
>>> cat('logrotate', 'test-deploy-run')
logs/run.log {
Modified: zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/tests.py
===================================================================
--- zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/tests.py 2013-03-22 15:10:18 UTC (rev 130164)
+++ zc.zdaemonrecipe/trunk/zc/zdaemonrecipe/tests.py 2013-03-26 17:44:30 UTC (rev 130165)
@@ -21,6 +21,15 @@
import zope.testing
from zope.testing import doctest, renormalizing
+try:
+ from zc.buildout.testing import not_found
+except ImportError:
+ not_found = (re.compile(r'Not found: [^\n]+/(\w|\.)+/\r?\n'), '')
+
+setuptools_or_distribute = (
+ re.compile(r"[d-] (setuptools|distribute)-"), "setuptools-")
+
+
def newlines_in_program():
"""
There can be newlines in the program option:
@@ -80,6 +89,8 @@
(re.compile('-\S+-py\d[.]\d(-\S+)?.egg'),
'-pyN.N.egg',
),
+ not_found,
+ setuptools_or_distribute,
])
def test_suite():
More information about the checkins
mailing list