Skip to content

Commit 52eefff

Browse files
committed
test: make the client read socket always available for reading to avoid getting blocked
1 parent 70427ba commit 52eefff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def is_ready(sock: Any) -> bool:
131131
return sock is not mock_sock or (fake_socket_handler.pending() > 0)
132132

133133
def handle_select(rlist: list, wlist: list, *args: Any) -> list:
134-
return [list(filter(is_ready, rlist)), list(filter(is_ready, wlist))]
134+
return [rlist, list(filter(is_ready, wlist))]
135135

136136
with patch("paho.mqtt.client.select.select", side_effect=handle_select):
137137
yield

0 commit comments

Comments
 (0)