@@ -38,38 +38,38 @@ def test_startup_nodes
3838 {
3939 config : ::RedisClient ::ClusterConfig . new ,
4040 want : {
41- '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 }
41+ '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
4242 }
4343 } ,
4444 {
4545 config : ::RedisClient ::ClusterConfig . new ( replica : true ) ,
4646 want : {
47- '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 }
47+ '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
4848 }
4949 } ,
5050 {
5151 config : ::RedisClient ::ClusterConfig . new ( fixed_hostname : 'endpoint.example.com' ) ,
5252 want : {
53- '127.0.0.1:6379' => { host : 'endpoint.example.com' , port : 6379 }
53+ '127.0.0.1:6379' => { host : 'endpoint.example.com' , port : 6379 , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
5454 }
5555 } ,
5656 {
5757 config : ::RedisClient ::ClusterConfig . new ( timeout : 1 ) ,
5858 want : {
59- '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , timeout : 1 }
59+ '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , timeout : 1 , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
6060 }
6161 } ,
6262 {
6363 config : ::RedisClient ::ClusterConfig . new ( nodes : [ 'redis://1.2.3.4:1234' , 'rediss://5.6.7.8:5678' ] ) ,
6464 want : {
65- '1.2.3.4:1234' => { host : '1.2.3.4' , port : 1234 } ,
66- '5.6.7.8:5678' => { host : '5.6.7.8' , port : 5678 , ssl : true }
65+ '1.2.3.4:1234' => { host : '1.2.3.4' , port : 1234 , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder } ,
66+ '5.6.7.8:5678' => { host : '5.6.7.8' , port : 5678 , ssl : true , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
6767 }
6868 } ,
6969 {
7070 config : ::RedisClient ::ClusterConfig . new ( custom : { foo : 'bar' } ) ,
7171 want : {
72- '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , custom : { foo : 'bar' } }
72+ '127.0.0.1:6379' => { host : '127.0.0.1' , port : 6379 , custom : { foo : 'bar' } , command_builder : :: RedisClient :: Cluster :: NoopCommandBuilder }
7373 }
7474 }
7575 ] . each_with_index do |c , idx |
@@ -182,13 +182,15 @@ def test_client_config_for_node
182182 nodes :
[ 'redis://username:[email protected] :1234' , 'rediss://5.6.7.8:5678' ] , 183183 custom : { foo : 'bar' }
184184 )
185- assert_equal ( {
186- host : '9.9.9.9' ,
187- port : 9999 ,
188- username : 'username' ,
189- password : 'password' ,
190- custom : { foo : 'bar' }
191- } , config . client_config_for_node ( '9.9.9.9:9999' ) )
185+ want = {
186+ host : '9.9.9.9' ,
187+ port : 9999 ,
188+ username : 'username' ,
189+ password : 'password' ,
190+ custom : { foo : 'bar' } ,
191+ command_builder : ::RedisClient ::Cluster ::NoopCommandBuilder
192+ }
193+ assert_equal ( want , config . client_config_for_node ( '9.9.9.9:9999' ) )
192194 end
193195
194196 def test_client_config_id
0 commit comments