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

Function test_write_dataset_schema_metadata

python/pyarrow/tests/test_dataset.py:5058–5067  ·  view source on GitHub ↗
(tempdir)

Source from the content-addressed store, hash-verified

5056
5057
5058def test_write_dataset_schema_metadata(tempdir):
5059 # ensure that schema metadata gets written
5060 from pyarrow import feather
5061
5062 table = pa.table({'a': [1, 2, 3]})
5063 table = table.replace_schema_metadata({b'key': b'value'})
5064 ds.write_dataset(table, tempdir, format="feather")
5065
5066 schema = feather.read_table(tempdir / "part-0.feather").schema
5067 assert schema.metadata == {b'key': b'value'}
5068
5069
5070@pytest.mark.parquet

Callers

nothing calls this directly

Calls 1

read_tableMethod · 0.45

Tested by

no test coverage detected