diff options
author | Mark Spruiell <mes@zeroc.com> | 2017-02-09 16:31:31 -0800 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2017-02-09 16:31:31 -0800 |
commit | af409fe78bdca7db6315ab0cc99ad063f8daecf7 (patch) | |
tree | b0079f556247a14f43e77ca6a31cb42df019485b /python/test/Ice/ami/TestI.py | |
parent | Fixed enum-related warnings (diff) | |
download | ice-af409fe78bdca7db6315ab0cc99ad063f8daecf7.tar.bz2 ice-af409fe78bdca7db6315ab0cc99ad063f8daecf7.tar.xz ice-af409fe78bdca7db6315ab0cc99ad063f8daecf7.zip |
ICE-7560 - more AMI test fixes, renaming ConnectionClose enumerators
Diffstat (limited to 'python/test/Ice/ami/TestI.py')
-rw-r--r-- | python/test/Ice/ami/TestI.py | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/python/test/Ice/ami/TestI.py b/python/test/Ice/ami/TestI.py index 53585189f29..75deb1d08b6 100644 --- a/python/test/Ice/ami/TestI.py +++ b/python/test/Ice/ami/TestI.py @@ -13,6 +13,7 @@ class TestIntfI(Test._TestIntfDisp): def __init__(self): self._cond = threading.Condition() self._batchCount = 0 + self._pending = [] def op(self, current=None): pass @@ -49,9 +50,30 @@ class TestIntfI(Test._TestIntfDisp): def sleep(self, ms, current=None): time.sleep(ms / 1000.0) + def startDispatch(self, current=None): + f = Ice.Future() + with self._cond: + self._pending.append(f) + return f + + def finishDispatch(self, current=None): + with self._cond: + for f in self._pending: + f.set_result(None) + self._pending = [] + def shutdown(self, current=None): + # + # Just in case a request arrived late. + # + with self._cond: + for f in self._pending: + f.set_result(None) current.adapter.getCommunicator().shutdown() + def supportsAMD(self, current=None): + return True + def supportsFunctionalTests(self, current=None): return False |