Skip to content

Commit

Permalink
Backport PR #58181 on branch 2.2.x (CI: correct error msg in test_vie…
Browse files Browse the repository at this point in the history
…w_index) (#58187)

Backport PR #58181: CI: correct error msg in `test_view_index`
  • Loading branch information
natmokval committed Apr 8, 2024
1 parent a947587 commit 691fc88
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pandas/tests/indexes/test_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,10 @@ def test_view_with_args_object_array_raises(self, index):
with pytest.raises(NotImplementedError, match="i8"):
index.view("i8")
else:
msg = "Cannot change data-type for object array"
msg = (
"Cannot change data-type for array of references|"
"Cannot change data-type for object array|"
)
with pytest.raises(TypeError, match=msg):
index.view("i8")

Expand Down

0 comments on commit 691fc88

Please sign in to comment.