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

Function _create_dataset_for_fragments

python/pyarrow/tests/test_dataset.py:1390–1404  ·  view source on GitHub ↗
(tempdir, chunk_size=None, filesystem=None)

Source from the content-addressed store, hash-verified

1388
1389@pytest.mark.parquet
1390def _create_dataset_for_fragments(tempdir, chunk_size=None, filesystem=None):
1391 table = pa.table(
1392 [range(8), [1] * 8, ['a'] * 4 + ['b'] * 4],
1393 names=['f1', 'f2', 'part']
1394 )
1395
1396 path = str(tempdir / "test_parquet_dataset")
1397
1398 pq.write_to_dataset(table, path,
1399 partition_cols=["part"], chunk_size=chunk_size)
1400 dataset = ds.dataset(
1401 path, format="parquet", partitioning="hive", filesystem=filesystem
1402 )
1403
1404 return table, dataset
1405
1406
1407@pytest.mark.parquet

Calls

no outgoing calls

Tested by

no test coverage detected