Author: Armin Rigo <[email protected]>
Branch:
Changeset: r2181:1ba1aa9565ff
Date: 2015-06-09 20:41 +0200
http://bitbucket.org/cffi/cffi/changeset/1ba1aa9565ff/
Log: Add some checks that will fail in PyPy
diff --git a/testing/cffi1/test_recompiler.py b/testing/cffi1/test_recompiler.py
--- a/testing/cffi1/test_recompiler.py
+++ b/testing/cffi1/test_recompiler.py
@@ -409,6 +409,10 @@
# 'x' is another <built-in method> object on lib, made very indirectly
x = type(lib).__dir__.__get__(lib)
py.test.raises(TypeError, ffi.typeof, x)
+ #
+ assert hasattr(lib.sin, '__name__') # present on built-in functions on
+ assert hasattr(lib.sin, '__module__') # CPython; must be emulated on PyPy
+ assert hasattr(lib.sin, '__doc__')
def test_verify_anonymous_struct_with_typedef():
ffi = FFI()
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit