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

Function test_flight_generator_stream_of_table

python/pyarrow/tests/test_flight.py:1476–1489  ·  view source on GitHub ↗

Try downloading a flight of Table in a GeneratorStream.

()

Source from the content-addressed store, hash-verified

1474
1475
1476def test_flight_generator_stream_of_table():
1477 """Try downloading a flight of Table in a GeneratorStream."""
1478 data = pa.Table.from_arrays([
1479 pa.array(range(0, 10 * 1024))
1480 ], names=['a'])
1481
1482 with EchoTableStreamFlightServer() as server, \
1483 FlightClient(('localhost', server.port)) as client:
1484 writer, _ = client.do_put(flight.FlightDescriptor.for_path('test'),
1485 data.schema)
1486 writer.write_table(data)
1487 writer.close()
1488 result = client.do_get(flight.Ticket(b'')).read_all()
1489 assert result.equals(data)
1490
1491
1492def test_flight_generator_stream_of_table_with_dict():

Callers

nothing calls this directly

Calls 8

FlightClientClass · 0.90
equalsMethod · 0.80
arrayMethod · 0.45
do_putMethod · 0.45
write_tableMethod · 0.45
closeMethod · 0.45
do_getMethod · 0.45

Tested by

no test coverage detected