[pypy-commit] cffi cffi-1.0: Test for f9eca71a085b
arigo
noreply at buildbot.pypy.org
Fri May 8 11:38:10 CEST 2015
Author: Armin Rigo <arigo at tunes.org>
Branch: cffi-1.0
Changeset: r1931:8bcd1c0658a4
Date: 2015-05-08 11:38 +0200
http://bitbucket.org/cffi/cffi/changeset/8bcd1c0658a4/
Log: Test for f9eca71a085b
diff --git a/_cffi1/test_ffi_obj.py b/_cffi1/test_ffi_obj.py
--- a/_cffi1/test_ffi_obj.py
+++ b/_cffi1/test_ffi_obj.py
@@ -63,7 +63,7 @@
def test_ffi_string():
ffi = _cffi1_backend.FFI()
- p = ffi.new("char[]", b"foobar\x00baz")
+ p = ffi.new("char[]", init=b"foobar\x00baz")
assert ffi.string(p) == b"foobar"
def test_ffi_errno():
@@ -111,7 +111,7 @@
assert ffi.getctype("int*", '') == "int *"
assert ffi.getctype("int*", 'x') == "int * x"
assert ffi.getctype("int", '*') == "int *"
- assert ffi.getctype("int", ' * x ') == "int * x"
+ assert ffi.getctype("int", replace_with=' * x ') == "int * x"
assert ffi.getctype(ffi.typeof("int*"), '*') == "int * *"
assert ffi.getctype("int", '[5]') == "int[5]"
assert ffi.getctype("int[5]", '[6]') == "int[6][5]"
diff --git a/_cffi1/test_new_ffi_1.py b/_cffi1/test_new_ffi_1.py
--- a/_cffi1/test_new_ffi_1.py
+++ b/_cffi1/test_new_ffi_1.py
@@ -1398,7 +1398,7 @@
assert p1 is p
assert p1[0] == 123
seen.append(1)
- q = ffi.gc(p, destructor)
+ q = ffi.gc(p, destructor=destructor)
import gc; gc.collect()
assert seen == []
del q
More information about the pypy-commit
mailing list