Skip to content

Commit 4e562f6

Browse files
add test for checking ndarray
1 parent 5a3e6f4 commit 4e562f6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/tests/arrays/test_array.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -451,10 +451,10 @@ def test_array_inference_fails(data):
451451
tm.assert_extension_array_equal(result, expected)
452452

453453

454-
@pytest.mark.parametrize("data", [np.array(0)])
454+
@pytest.mark.parametrize("data,dtype", [([np.array(0)],"int64"),(np.array([[1, 2], ["a", "b"]]),object)])
455455
def test_nd_raises(data):
456456
with pytest.raises(ValueError, match="NumpyExtensionArray must be 1-dimensional"):
457-
pd.array(data, dtype="int64")
457+
pd.array(data, dtype=dtype)
458458

459459

460460
def test_scalar_raises():

0 commit comments

Comments
 (0)