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

Function test_leak3

python/scripts/test_leak.py:80–95  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

78
79
80def test_leak3():
81 import pyarrow.parquet as pq
82
83 df = pd.DataFrame({f'a{i}': [1, 2, 3, 4] for i in range(50)})
84 table = pa.Table.from_pandas(df, preserve_index=False)
85
86 writer = pq.ParquetWriter('leak_test_' + rands(5) + '.parquet',
87 table.schema)
88
89 def func():
90 writer.write_table(table, row_group_size=len(table))
91
92 # This does not "leak" per se but we do want to have this use as little
93 # memory as possible
94 assert_does_not_leak(func, iterations=500,
95 check_interval=50, tolerance=20)
96
97
98def test_ARROW_8801():

Callers

nothing calls this directly

Calls 2

randsFunction · 0.90
assert_does_not_leakFunction · 0.85

Tested by

no test coverage detected