[pypy-commit] pypy default: More tests from cffi
arigo
pypy.commits at gmail.com
Sat Sep 15 17:53:53 EDT 2018
Author: Armin Rigo <arigo at tunes.org>
Branch:
Changeset: r95124:20239d9e5ce9
Date: 2018-09-15 23:49 +0200
http://bitbucket.org/pypy/pypy/changeset/20239d9e5ce9/
Log: More tests from cffi
diff --git a/pypy/module/_cffi_backend/test/_backend_test_c.py b/pypy/module/_cffi_backend/test/_backend_test_c.py
--- a/pypy/module/_cffi_backend/test/_backend_test_c.py
+++ b/pypy/module/_cffi_backend/test/_backend_test_c.py
@@ -334,6 +334,10 @@
max = (1 << (8*size-1)) - 1
assert newp(pp, min)[0] == min
assert newp(pp, max)[0] == max
+ py.test.raises(OverflowError, newp, pp, min - 2 ** 32)
+ py.test.raises(OverflowError, newp, pp, min - 2 ** 64)
+ py.test.raises(OverflowError, newp, pp, max + 2 ** 32)
+ py.test.raises(OverflowError, newp, pp, max + 2 ** 64)
py.test.raises(OverflowError, newp, pp, min - 1)
py.test.raises(OverflowError, newp, pp, max + 1)
py.test.raises(OverflowError, newp, pp, min - 1 - 2 ** 32)
More information about the pypy-commit
mailing list