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

Function test_boolean_nulls

python/pyarrow/tests/test_feather.py:330–345  ·  view source on GitHub ↗
(version)

Source from the content-addressed store, hash-verified

328
329@pytest.mark.pandas
330def test_boolean_nulls(version):
331 # pandas requires upcast to object dtype
332 path = random_path()
333 TEST_FILES.append(path)
334
335 num_values = 100
336 np.random.seed(0)
337
338 mask = np.random.randint(0, 10, size=num_values) < 3
339 values = np.random.randint(0, 10, size=num_values) < 5
340
341 table = pa.table([pa.array(values, mask=mask)], names=['bools'])
342 _check_arrow_roundtrip(table)
343
344 df = table.to_pandas()
345 _check_pandas_roundtrip(df, version=version)
346
347
348def test_buffer_bounds_error(version):

Callers

nothing calls this directly

Calls 5

random_pathFunction · 0.85
_check_arrow_roundtripFunction · 0.85
_check_pandas_roundtripFunction · 0.70
appendMethod · 0.45
arrayMethod · 0.45

Tested by

no test coverage detected