Commit b7e27555 authored by Jeremy Hylton's avatar Jeremy Hylton

Remove Python 2.x-isms so that tests run under Python 1.5.2

parent 933086e3
......@@ -23,4 +23,4 @@ class IteratorStorage:
assert rec.serial == revid
assert rec.version == ''
assert zodb_unpickle(rec.data) == MinPO(val)
val += 1
val = val + 1
......@@ -53,8 +53,8 @@ def zodb_unpickle(data):
try:
klass = ns[klassname]
except KeyError:
print >> sys.stderr, "can't find %s in %s" % (klassname,
repr(ns))
sys.stderr.write("can't find %s in %s" % (klassname,
repr(ns)))
inst = klass()
else:
raise ValueError, "expected class info: %s" % repr(klass_info)
......
......@@ -59,15 +59,17 @@ TID = "\000" * 8
class SynchronizedStorage:
def verifyCommitting(self, callable, *args):
self.assertRaises(StorageTransactionError, callable *args)
## def verifyCommitting(self, callable, *args):
## self.assertRaises(StorageTransactionError, callable *args)
def verifyNotCommitting(self, callable, *args):
self.assertRaises(StorageTransactionError, callable, *args)
args = (StorageTransactionError, callable) + args
apply(self.assertRaises, args)
def verifyWrongTrans(self, callable, *args):
self._storage.tpc_begin(self._transaction)
self.assertRaises(StorageTransactionError, callable, *args)
args = (StorageTransactionError, callable) + args
apply(self.assertRaises, args)
def checkAbortVersionNotCommitting(self):
self.verifyNotCommitting(self._storage.abortVersion,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment