Skip to content

Commit ca0fdaf

Browse files
Clean up DummyConnection in test_connection_pool.py
Removed unnecessary methods and attributes from the DummyConnection class that were introduced during development. This restores the class to its minimal implementation needed for testing the MaxConnectionsError behavior.
1 parent 229f857 commit ca0fdaf

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

tests/test_connection_pool.py

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -26,22 +26,12 @@ class DummyConnection:
2626
def __init__(self, **kwargs):
2727
self.kwargs = kwargs
2828
self.pid = os.getpid()
29-
self.connected = False
3029

3130
def connect(self):
32-
self.connected = True
33-
34-
def disconnect(self):
35-
self.connected = False
36-
31+
pass
32+
3733
def can_read(self):
3834
return False
39-
40-
def send_command(self, *args, **kwargs):
41-
pass
42-
43-
def read_response(self, disable_decoding=False, **kwargs):
44-
return "PONG"
4535

4636

4737
class TestConnectionPool:

0 commit comments

Comments
 (0)