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

Method check_reader

python/pyarrow/tests/test_csv.py:1669–1676  ·  view source on GitHub ↗
(self, reader, expected_schema, expected_data)

Source from the content-addressed store, hash-verified

1667 return self.open_csv(pa.py_buffer(b), **kwargs)
1668
1669 def check_reader(self, reader, expected_schema, expected_data):
1670 assert reader.schema == expected_schema
1671 batches = list(reader)
1672 assert len(batches) == len(expected_data)
1673 for batch, expected_batch in zip(batches, expected_data):
1674 batch.validate(full=True)
1675 assert batch.schema == expected_schema
1676 assert batch.to_pydict() == expected_batch
1677
1678 def read_bytes(self, b, **kwargs):
1679 return self.open_bytes(b, **kwargs).read_all()

Callers 7

test_file_objectMethod · 0.95
test_headerMethod · 0.95
test_inferenceMethod · 0.95
test_column_optionsMethod · 0.95
test_encodingMethod · 0.95

Calls 3

listFunction · 0.85
lenFunction · 0.85
validateMethod · 0.45

Tested by

no test coverage detected