File tree Expand file tree Collapse file tree 4 files changed +15
-3
lines changed Expand file tree Collapse file tree 4 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ services:
103103 - all
104104
105105 redis-stack :
106- image : ${REDIS_STACK_IMAGE:-redis/redis-stack-server:edge }
106+ image : ${REDIS_STACK_IMAGE:-redis/redis-stack-server:latest }
107107 container_name : redis-stack
108108 ports :
109109 - 6479:6379
@@ -112,6 +112,7 @@ services:
112112 profiles :
113113 - standalone
114114 - all-stack
115+ - all
115116
116117 redis-stack-graph :
117118 image : redis/redis-stack-server:6.2.6-v15
Original file line number Diff line number Diff line change 11import asyncio
22import socket
33import types
4+ from errno import ECONNREFUSED
45from unittest .mock import patch
56
67import pytest
@@ -534,7 +535,8 @@ async def test_network_connection_failure():
534535 with pytest .raises (ConnectionError ) as e :
535536 redis = Redis (host = "127.0.0.1" , port = 9999 )
536537 await redis .set ("a" , "b" )
537- assert str (e .value ).startswith ("Error 111 connecting to 127.0.0.1:9999. Connect" )
538+ expected_err = f"Error { ECONNREFUSED } connecting to 127.0.0.1:9999. Connect"
539+ assert str (e .value ).startswith (expected_err )
538540
539541
540542async def test_unix_socket_connection_failure ():
Original file line number Diff line number Diff line change 44import sys
55import threading
66import types
7+ from errno import ECONNREFUSED
78from typing import Any
89from unittest import mock
910from unittest .mock import call , patch
@@ -352,7 +353,11 @@ def test_network_connection_failure():
352353 with pytest .raises (ConnectionError ) as e :
353354 redis = Redis (port = 9999 )
354355 redis .set ("a" , "b" )
355- assert str (e .value ) == "Error 111 connecting to localhost:9999. Connection refused."
356+
357+ assert (
358+ str (e .value )
359+ == f"Error { ECONNREFUSED } connecting to localhost:9999. Connection refused."
360+ )
356361
357362
358363def test_unix_socket_connection_failure ():
Original file line number Diff line number Diff line change 11import contextlib
22import multiprocessing
3+ import sys
34
45import pytest
56import redis
89
910from .conftest import _get_client
1011
12+ if sys .platform == "darwin" :
13+ multiprocessing .set_start_method ("fork" , force = True )
14+
1115
1216@contextlib .contextmanager
1317def exit_callback (callback , * args ):
You can’t perform that action at this time.
0 commit comments