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

Function test_v2_set_chunksize

python/pyarrow/tests/test_feather.py:626–637  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

624
625@pytest.mark.pandas
626def test_v2_set_chunksize():
627 df = pd.DataFrame({'A': np.arange(1000)})
628 table = pa.table(df)
629
630 buf = io.BytesIO()
631 write_feather(table, buf, chunksize=250, version=2)
632
633 result = buf.getvalue()
634
635 ipc_file = pa.ipc.open_file(pa.BufferReader(result))
636 assert ipc_file.num_record_batches == 4
637 assert len(ipc_file.get_batch(0)) == 250
638
639
640@pytest.mark.pandas

Callers

nothing calls this directly

Calls 3

write_featherFunction · 0.90
lenFunction · 0.85
BufferReaderMethod · 0.80

Tested by

no test coverage detected