diff options
Diffstat (limited to 'py/test/Ice/exceptions/AllTests.py')
-rw-r--r-- | py/test/Ice/exceptions/AllTests.py | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/py/test/Ice/exceptions/AllTests.py b/py/test/Ice/exceptions/AllTests.py index bbc89a0e0a3..6fadedc2edc 100644 --- a/py/test/Ice/exceptions/AllTests.py +++ b/py/test/Ice/exceptions/AllTests.py @@ -9,12 +9,6 @@ import Ice, Test, threading, sys, array -# -# xrange is not supported with python >= 3.x -# -if sys.version_info[0] >= 3: - xrange = range - def test(b): if not b: raise RuntimeError('test assertion failed') @@ -708,7 +702,7 @@ def allTests(communicator): test(False) try: - thrower.throwMemoryLimitException(array.array('B', (0 for x in xrange(20 * 1024)))) # 20KB + thrower.throwMemoryLimitException(bytearray(20 * 1024)) # 20KB test(False) except Ice.MemoryLimitException: pass @@ -716,8 +710,7 @@ def allTests(communicator): test(False) try: - thrower.end_throwMemoryLimitException( - thrower.begin_throwMemoryLimitException(array.array('B', (0 for x in xrange(20 * 1024))))) # 20KB + thrower.end_throwMemoryLimitException(thrower.begin_throwMemoryLimitException(bytearray(20 * 1024))) # 20KB test(False) except Ice.MemoryLimitException: pass |