Skip to content

Commit

Permalink
update message
Browse files Browse the repository at this point in the history
  • Loading branch information
jbrockmendel committed Aug 22, 2024
1 parent c498d20 commit 7f10e72
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pandas/tests/groupby/test_raises.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,13 @@ def test_groupby_raises_string(
elif groupby_func in ["cummin", "cummax"]:
msg = msg.replace("object", "str")
elif groupby_func == "corrwith":
msg = "'.*NumpySemantics' with dtype str does not support operation 'mean'"
if df["d"].dtype.storage == "pyarrow":
msg = (
"ArrowStringArrayNumpySemantics' with dtype str does not "
"support operation 'mean'"
)
else:
msg = "Cannot perform reduction 'mean' with string dtype"

if groupby_func == "fillna":
kind = "Series" if groupby_series else "DataFrame"
Expand Down

0 comments on commit 7f10e72

Please sign in to comment.