[Neo-report] r2698 jm - in /trunk/neo: client/Storage.py scripts/runner.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Thu Mar 31 19:51:26 CEST 2011
Author: jm
Date: Thu Mar 31 19:51:26 2011
New Revision: 2698
Log:
Add some compatibility with ZODB 3.9
Modified:
trunk/neo/client/Storage.py
trunk/neo/scripts/runner.py
Modified: trunk/neo/client/Storage.py
==============================================================================
--- trunk/neo/client/Storage.py [iso-8859-1] (original)
+++ trunk/neo/client/Storage.py [iso-8859-1] Thu Mar 31 19:51:26 2011
@@ -48,7 +48,7 @@ class Storage(BaseStorage.BaseStorage,
_snapshot_tid = None
- implements(
+ implements(*filter(None, (
ZODB.interfaces.IStorage,
# "restore" missing for the moment, but "store" implements this
# interface.
@@ -59,9 +59,9 @@ class Storage(BaseStorage.BaseStorage,
# ZODB.interfaces.IStorageIteration,
ZODB.interfaces.IStorageUndoable,
ZODB.interfaces.IExternalGC,
- ZODB.interfaces.ReadVerifyingStorage,
+ getattr(ZODB.interfaces, 'ReadVerifyingStorage', None), # XXX ZODB 3.9
ZODB.interfaces.IMVCCStorage,
- )
+ )))
def __init__(self, master_nodes, name, connector=None, read_only=False,
compress=None, logfile=None, verbose=False,
Modified: trunk/neo/scripts/runner.py
==============================================================================
--- trunk/neo/scripts/runner.py [iso-8859-1] (original)
+++ trunk/neo/scripts/runner.py [iso-8859-1] Thu Mar 31 19:51:26 2011
@@ -291,7 +291,12 @@ class TestRunner(BenchmarkRunner):
if config.functional:
runner.run('Functional tests', FUNC_TEST_MODULES)
if config.zodb:
- runner.run('ZODB tests', ZODB_TEST_MODULES)
+ try:
+ from ZODB.interfaces import ReadVerifyingStorage
+ except ImportError:
+ logging.warn(" ZODB tests disabled on ZODB 3.9")
+ else:
+ runner.run('ZODB tests', ZODB_TEST_MODULES)
except KeyboardInterrupt:
config['mail_to'] = None
traceback.print_exc()
More information about the Neo-report
mailing list