[Neo-report] r1905 gregory - in /trunk: neo/tests/zodb/testRecovery.py tools/runner
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Mar 5 22:24:21 CET 2010
Author: gregory
Date: Fri Mar 5 22:24:21 2010
New Revision: 1905
Log:
Add (but disable) storage recovery tests.
Added:
trunk/neo/tests/zodb/testRecovery.py
Modified:
trunk/tools/runner
Added: trunk/neo/tests/zodb/testRecovery.py
==============================================================================
--- trunk/neo/tests/zodb/testRecovery.py (added)
+++ trunk/neo/tests/zodb/testRecovery.py [iso-8859-1] Fri Mar 5 22:24:21 2010
@@ -1,0 +1,53 @@
+#
+# Copyright (C) 2009-2010 Nexedi SA
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+import os
+import unittest
+import ZODB
+
+from ZODB.tests.RecoveryStorage import RecoveryStorage
+from ZODB.tests.StorageTestBase import StorageTestBase
+
+from neo.tests.functional import NEOCluster
+from neo.tests.zodb import ZODBTestCase
+
+class RecoveryTests(ZODBTestCase, StorageTestBase, RecoveryStorage):
+
+ def setUp(self):
+ super(RecoveryTests, self).setUp()
+ dst_temp_dir = self.getTempDirectory() + '-dst'
+ if not os.path.exists(dst_temp_dir):
+ os.makedirs(dst_temp_dir)
+ self.neo_dst = NEOCluster(['test_neo1-dst'],
+ partitions=1, replicas=0, port_base=10000,
+ master_node_count=1, temp_dir=dst_temp_dir)
+ self.neo_dst.stop()
+ self.neo_dst.setupDB()
+ self.neo_dst.start()
+ self._dst = self.neo.getZODBStorage()
+ self._dst_db = ZODB.DB(self._dst)
+
+ def tearDown(self):
+ super(RecoveryTests, self).tearDown()
+ self._dst_db.close()
+ self._dst.cleanup()
+ self.neo_dst.stop()
+
+if __name__ == "__main__":
+ suite = unittest.makeSuite(RecoveryTests, 'check')
+ unittest.main(defaultTest='suite')
+
Modified: trunk/tools/runner
==============================================================================
--- trunk/tools/runner [iso-8859-1] (original)
+++ trunk/tools/runner [iso-8859-1] Fri Mar 5 22:24:21 2010
@@ -80,6 +80,7 @@
('neo.tests.zodb.testPersistent', 'check'),
('neo.tests.zodb.testReadOnly', 'check'),
('neo.tests.zodb.testRevision', 'check'),
+ #('neo.tests.zodb.testRecovery', 'check'),
('neo.tests.zodb.testSynchronization', 'check'),
# ('neo.tests.zodb.testVersion', 'check'),
('neo.tests.zodb.testUndo', 'check'),
More information about the Neo-report
mailing list