MCPcopy Create free account
hub / github.com/apache/arrow / test_roundtrip_chunked_array_capsule

Function test_roundtrip_chunked_array_capsule

python/pyarrow/tests/test_cffi.py:750–757  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

748
749
750def test_roundtrip_chunked_array_capsule():
751 chunked = pa.chunked_array([pa.array(["a", "b", "c"])])
752
753 capsule = chunked.__arrow_c_stream__()
754 assert PyCapsule_IsValid(capsule, b"arrow_array_stream") == 1
755 imported_chunked = pa.ChunkedArray._import_from_c_capsule(capsule)
756 assert imported_chunked.type == chunked.type
757 assert imported_chunked == chunked
758
759
760def test_roundtrip_chunked_array_capsule_requested_schema():

Callers

nothing calls this directly

Calls 4

chunked_arrayMethod · 0.80
PyCapsule_IsValidFunction · 0.70
arrayMethod · 0.45
__arrow_c_stream__Method · 0.45

Tested by

no test coverage detected