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

Function test_to_numpy_timedelta64

python/pyarrow/tests/test_array.py:272–276  ·  view source on GitHub ↗
(unit)

Source from the content-addressed store, hash-verified

270@pytest.mark.numpy
271@pytest.mark.parametrize('unit', ['s', 'ms', 'us', 'ns'])
272def test_to_numpy_timedelta64(unit):
273 arr = pa.array([1, 2, 3], pa.duration(unit))
274 expected = np.array([1, 2, 3], dtype=f"timedelta64[{unit}]")
275 np_arr = arr.to_numpy()
276 np.testing.assert_array_equal(np_arr, expected)
277
278
279@pytest.mark.numpy

Callers

nothing calls this directly

Calls 1

arrayMethod · 0.45

Tested by

no test coverage detected