From dff3c9e0274f3dde3d3f55d437650b59e5168f1f Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Mon, 8 Feb 2010 11:08:37 +0100 Subject: [PATCH] new test case for ticket #505 (cimport cython) --- tests/run/cimport_cython_T505.pyx | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 tests/run/cimport_cython_T505.pyx diff --git a/tests/run/cimport_cython_T505.pyx b/tests/run/cimport_cython_T505.pyx new file mode 100644 index 00000000..13a89d83 --- /dev/null +++ b/tests/run/cimport_cython_T505.pyx @@ -0,0 +1,11 @@ +cimport cython + +cdef extern from "Python.h": + cdef cython.unicode PyUnicode_DecodeUTF8(char* s, Py_ssize_t size, char* errors) + +def test_capi(): + """ + >>> print(test_capi()) + abc + """ + return PyUnicode_DecodeUTF8("abc", 3, NULL) -- 2.26.2