Commit c19bae1d authored by Albertas Agejevas's avatar Albertas Agejevas

More trivial Py3 problems.

parent f07858e6
...@@ -1023,7 +1023,7 @@ def tpc_finish_error(): ...@@ -1023,7 +1023,7 @@ def tpc_finish_error():
... def register_object(self, ob): ... def register_object(self, ob):
... pass ... pass
... def close(self): ... def close(self):
... print 'connection closed' ... print('connection closed')
... trigger = property(lambda self: self) ... trigger = property(lambda self: self)
... pull_trigger = lambda self, func, *args: func(*args) ... pull_trigger = lambda self, func, *args: func(*args)
...@@ -1045,25 +1045,25 @@ def tpc_finish_error(): ...@@ -1045,25 +1045,25 @@ def tpc_finish_error():
... def endZeoVerify(self): ... def endZeoVerify(self):
... self.conn.client.endVerify() ... self.conn.client.endVerify()
... def lastTransaction(self): ... def lastTransaction(self):
... return '\0'*8 ... return b'\0'*8
... def tpc_begin(self, t, *args): ... def tpc_begin(self, t, *args):
... if self.t is not None: ... if self.t is not None:
... raise TypeError('already trans') ... raise TypeError('already trans')
... self.t = t ... self.t = t
... print 'begin', args ... print('begin', args)
... def vote(self, t): ... def vote(self, t):
... if self.t != t: ... if self.t != t:
... raise TypeError('bad trans') ... raise TypeError('bad trans')
... print 'vote' ... print('vote')
... def tpc_finish(self, *args): ... def tpc_finish(self, *args):
... if self.should_fail: ... if self.should_fail:
... raise TypeError() ... raise TypeError()
... print 'finish' ... print('finish')
... def tpc_abort(self, t): ... def tpc_abort(self, t):
... if self.t != t: ... if self.t != t:
... raise TypeError('bad trans') ... raise TypeError('bad trans')
... self.t = None ... self.t = None
... print 'abort' ... print('abort')
... def iterator_gc(*args): ... def iterator_gc(*args):
... pass ... pass
...@@ -1106,7 +1106,7 @@ def tpc_finish_error(): ...@@ -1106,7 +1106,7 @@ def tpc_finish_error():
>>> cs._update_cache = lambda : None >>> cs._update_cache = lambda : None
>>> try: cs.tpc_finish(t2) >>> try: cs.tpc_finish(t2)
... except: pass ... except: pass
... else: print "Should have failed" ... else: print("Should have failed")
finish finish
connection closed connection closed
...@@ -1146,7 +1146,7 @@ def client_has_newer_data_than_server(): ...@@ -1146,7 +1146,7 @@ def client_has_newer_data_than_server():
>>> db.close() >>> db.close()
>>> for record in handler.records[:5]: >>> for record in handler.records[:5]:
... print formatter.format(record) ... print(formatter.format(record))
... # doctest: +ELLIPSIS +NORMALIZE_WHITESPACE ... # doctest: +ELLIPSIS +NORMALIZE_WHITESPACE
ZEO.ClientStorage CRITICAL client ZEO.ClientStorage CRITICAL client
Client has seen newer transactions than server! Client has seen newer transactions than server!
......
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