diff --git a/pandas/tests/test_common.py b/pandas/tests/test_common.py index fe24755e8cc23..4af71be11fe6b 100644 --- a/pandas/tests/test_common.py +++ b/pandas/tests/test_common.py @@ -286,4 +286,7 @@ def test_pyarrow_missing_warn(module): please provide us feedback at https://github.com/pandas-dev/pandas/issues/54466 """ # noqa: E501 stderr_msg = response.stderr.decode("utf-8") - assert msg in stderr_msg, stderr_msg + # Split by \n to avoid \r\n vs \n differences on Windows/Unix + # https://stackoverflow.com/questions/11989501/replacing-r-n-with-n + stderr_msg = "\n".join(stderr_msg.splitlines()) + assert msg in stderr_msg