diff options
author | Armin Rigo <arigo@tunes.org> | 2020-02-07 10:00:28 +0100 |
---|---|---|
committer | Armin Rigo <arigo@tunes.org> | 2020-02-07 10:00:28 +0100 |
commit | fd32626a37916db215f48c1c6afee2253ae4ee96 (patch) | |
tree | 960def6b25ee8a00d554da3cdc3288ed8f83f1b8 /extra_tests/cffi_tests/cffi0/test_function.py | |
parent | Change the FAQ entry "why not github" (diff) | |
download | pypy-fd32626a37916db215f48c1c6afee2253ae4ee96.tar.gz pypy-fd32626a37916db215f48c1c6afee2253ae4ee96.tar.bz2 pypy-fd32626a37916db215f48c1c6afee2253ae4ee96.zip |
update to cffi/f2ec51ca7510
Diffstat (limited to 'extra_tests/cffi_tests/cffi0/test_function.py')
-rw-r--r-- | extra_tests/cffi_tests/cffi0/test_function.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/extra_tests/cffi_tests/cffi0/test_function.py b/extra_tests/cffi_tests/cffi0/test_function.py index 8b6bf821a3..084a97bfb2 100644 --- a/extra_tests/cffi_tests/cffi0/test_function.py +++ b/extra_tests/cffi_tests/cffi0/test_function.py @@ -521,3 +521,16 @@ class TestFunction(object): assert str(e.value).startswith("library '") assert str(e.value).endswith("' has already been closed") ffi.dlclose(lib) # does not raise + + def test_passing_large_list(self): + if self.Backend is CTypesBackend: + py.test.skip("the ctypes backend doesn't support this") + ffi = FFI(backend=self.Backend()) + ffi.cdef(""" + void getenv(char *); + """) + needs_dlopen_none() + m = ffi.dlopen(None) + arg = [b"F", b"O", b"O"] + [b"\x00"] * 20000000 + x = m.getenv(arg) + assert x is None |