Commit f36dbda7 authored by Stefan Behnel's avatar Stefan Behnel

work around Python inconsistency in test case

parent 6fcb8ca7
...@@ -8,10 +8,9 @@ __doc__ = u""" ...@@ -8,10 +8,9 @@ __doc__ = u"""
>>> str(test((1<<32)-1)) >>> str(test((1<<32)-1))
'4294967295' '4294967295'
>>> test(-1) #doctest: +ELLIPSIS >>> try: test(-1)
Traceback (most recent call last): ... except (OverflowError, TypeError): print("ERROR")
... ERROR
OverflowError: ...
>>> test(1<<128) #doctest: +ELLIPSIS >>> test(1<<128) #doctest: +ELLIPSIS
Traceback (most recent call last): Traceback (most recent call last):
...@@ -25,10 +24,9 @@ True ...@@ -25,10 +24,9 @@ True
True True
>>> a.foo(5) >>> a.foo(5)
5 5
>>> a.foo(-1) #doctest: +ELLIPSIS >>> try: a.foo(-1)
Traceback (most recent call last): ... except (OverflowError, TypeError): print("ERROR")
... ERROR
OverflowError: ...
>>> a.foo(1 << 180) #doctest: +ELLIPSIS >>> a.foo(1 << 180) #doctest: +ELLIPSIS
Traceback (most recent call last): Traceback (most recent call last):
... ...
......
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