[Zope3-checkins] CVS: ZODB4/ZEO/tests - testConnection.py:1.3
Barry Warsaw
barry@wooz.org
Mon, 16 Dec 2002 18:07:22 -0500
Update of /cvs-repository/ZODB4/ZEO/tests
In directory cvs.zope.org:/tmp/cvs-serv22896
Modified Files:
testConnection.py
Log Message:
BerkeleyStorageConfig.getConfig(): Use "yes" and "no" for boolean
values. Also, a minor code cleanup.
=== ZODB4/ZEO/tests/testConnection.py 1.2 => 1.3 ===
--- ZODB4/ZEO/tests/testConnection.py:1.2 Mon Dec 16 16:16:10 2002
+++ ZODB4/ZEO/tests/testConnection.py Mon Dec 16 18:07:22 2002
@@ -25,7 +25,7 @@
class FileStorageConfig:
def getConfig(self, path, create, read_only):
- s = """\
+ return """\
<Storage>
type FileStorage
file_name %s
@@ -34,7 +34,7 @@
</Storage>""" % (path,
create and 'yes' or 'no',
read_only and 'yes' or 'no')
- return s
+
class BerkeleyStorageConfig:
def getConfig(self, path, create, read_only):
@@ -44,7 +44,8 @@
type BDBFullStorage
name %s
read_only %s
- </Storage>""" % (path, read_only)
+ </Storage>""" % (path,
+ read_only and 'yes' or 'no')
class FileStorageConnectionTests(