(self, getaddrinfo: MagicMock)
| 881 | |
| 882 | @patch("socket.getaddrinfo") |
| 883 | def test_create_connection_error(self, getaddrinfo: MagicMock) -> None: |
| 884 | getaddrinfo.return_value = [] |
| 885 | with pytest.raises(OSError, match="getaddrinfo returns an empty list"): |
| 886 | create_connection(("example.com", 80)) |
| 887 | |
| 888 | @patch("socket.getaddrinfo") |
| 889 | def test_dnsresolver_forced_error(self, getaddrinfo: MagicMock) -> None: |
nothing calls this directly
no test coverage detected