(tmpdir)
| 2071 | |
| 2072 | |
| 2073 | def test_output_stream_file_path(tmpdir): |
| 2074 | data = b"some test data\n" * 10 + b"eof\n" |
| 2075 | file_path = tmpdir / 'output_stream' |
| 2076 | |
| 2077 | def check_data(file_path, data): |
| 2078 | with pa.output_stream(file_path) as stream: |
| 2079 | stream.write(data) |
| 2080 | with open(str(file_path), 'rb') as f: |
| 2081 | assert f.read() == data |
| 2082 | |
| 2083 | check_data(file_path, data) |
| 2084 | check_data(str(file_path), data) |
| 2085 | check_data(pathlib.Path(str(file_path)), data) |
| 2086 | |
| 2087 | |
| 2088 | @pytest.mark.gzip |
nothing calls this directly
no test coverage detected