diff --git a/tests/test_asyncio/test_connection.py b/tests/test_asyncio/test_connection.py index 9a3d4bcaac..fefa3003c0 100644 --- a/tests/test_asyncio/test_connection.py +++ b/tests/test_asyncio/test_connection.py @@ -549,21 +549,3 @@ async def test_unix_socket_connection_failure(): str(e.value) == "Error 2 connecting to unix:///tmp/a.sock. No such file or directory." ) - - -@pytest.mark.parametrize( - "error, expected_message", - [ - (OSError(), "Error connecting to localhost:6379. Connection reset by peer"), - (OSError(12), "Error connecting to localhost:6379. 12."), - ( - OSError(12, "Some Error"), - "Error 12 connecting to localhost:6379. [Errno 12] Some Error.", - ), - ], -) -async def test_connect_error_message(error, expected_message): - """Test that the _error_message function formats errors correctly""" - conn = Connection() - error_message = conn._error_message(error) - assert error_message == expected_message