[Zodb-checkins] CVS: ZODB3/ZEO/tests - forker.py:1.21.2.2 winserver.py:1.11.2.1
Tim Peters
tim.one@comcast.net
Mon, 3 Feb 2003 14:07:22 -0500
Update of /cvs-repository/ZODB3/ZEO/tests
In directory cvs.zope.org:/tmp/cvs-serv15613/ZEO/tests
Modified Files:
Tag: ZODB3-3_1-branch
forker.py winserver.py
Log Message:
transaction_timeout wasn't being passed to the server on Windows,
causing checkTimeout to fail. Fixed, and all tests pass on Windows
under 2.1.3 and 2.2.2 now.
=== ZODB3/ZEO/tests/forker.py 1.21.2.1 => 1.21.2.2 ===
--- ZODB3/ZEO/tests/forker.py:1.21.2.1 Mon Jan 20 16:54:28 2003
+++ ZODB3/ZEO/tests/forker.py Mon Feb 3 14:07:19 2003
@@ -64,6 +64,8 @@
prefix = (sys.executable, script, "-r")
else:
prefix = (sys.executable, script)
+ if transaction_timeout is not None:
+ prefix += ("-t", repr(transaction_timeout))
args = prefix + (str(port), storage_name) + args
d = os.environ.copy()
d['PYTHONPATH'] = os.pathsep.join(sys.path)
=== ZODB3/ZEO/tests/winserver.py 1.11 => 1.11.2.1 ===
--- ZODB3/ZEO/tests/winserver.py:1.11 Tue Oct 1 14:13:10 2002
+++ ZODB3/ZEO/tests/winserver.py Mon Feb 3 14:07:19 2003
@@ -55,6 +55,11 @@
if args[0] == "-r":
ro_svr = 1
del args[0]
+ transaction_timeout = None
+ if args[0] == '-t':
+ assert len(args) >= 2
+ transaction_timeout = float(args[1])
+ del args[:2]
port, storage_name, rawargs = args[0], args[1], args[2:]
klass = load_storage_class(storage_name)
args = []
@@ -67,7 +72,8 @@
test_port = zeo_port + 1
t = ZEOTestServer(('', test_port), storage)
addr = ('', zeo_port)
- serv = ZEO.StorageServer.StorageServer(addr, {'1': storage}, ro_svr)
+ serv = ZEO.StorageServer.StorageServer(addr, {'1': storage}, ro_svr,
+ transaction_timeout=transaction_timeout)
asyncore.loop()
# XXX The code below is evil because it can cause deadlocks in zrpc.
# (To fix it, calling ThreadedAsync._start_loop() might help.)