@@ -248,9 +248,11 @@ public function testSSLConnectionParameters()
248
248
$ this ->assertArrayHasKey (6 , $ instance ->constructParams );
249
249
$ options = $ instance ->constructParams [6 ];
250
250
$ this ->assertArrayHasKey ('ssl_context ' , $ options );
251
- $ context = $ options ['ssl_context ' ];
251
+ $ this ->assertArrayHasKey ('context ' , $ options );
252
+ $ context = $ options ['context ' ];
252
253
// unset to check whole array at once later
253
254
$ instance ->constructParams [6 ]['ssl_context ' ] = null ;
255
+ $ instance ->constructParams [6 ]['context ' ] = null ;
254
256
$ this ->assertIsResource ($ context );
255
257
$ this ->assertEquals ('stream-context ' , get_resource_type ($ context ));
256
258
$ options = stream_context_get_options ($ context );
@@ -272,6 +274,7 @@ public function testSSLConnectionParameters()
272
274
'connection_timeout ' => 3 ,
273
275
'read_write_timeout ' => 3 ,
274
276
'ssl_context ' => null , // context checked earlier
277
+ 'context ' => null , // context checked earlier
275
278
'keepalive ' => false ,
276
279
'heartbeat ' => 0 ,
277
280
]
@@ -455,9 +458,11 @@ public function testSSLClusterConnectionParameters()
455
458
$ this ->assertArrayHasKey (6 , $ instance ->constructParams );
456
459
$ options = $ instance ->constructParams [6 ];
457
460
$ this ->assertArrayHasKey ('ssl_context ' , $ options );
458
- $ context = $ options ['ssl_context ' ];
461
+ $ this ->assertArrayHasKey ('context ' , $ options );
462
+ $ context = $ options ['context ' ];
459
463
// unset to check whole array at once later
460
464
$ instance ->constructParams [6 ]['ssl_context ' ] = null ;
465
+ $ instance ->constructParams [6 ]['context ' ] = null ;
461
466
$ this ->assertIsResource ($ context );
462
467
$ this ->assertEquals ('stream-context ' , get_resource_type ($ context ));
463
468
$ options = stream_context_get_options ($ context );
@@ -466,9 +471,10 @@ public function testSSLClusterConnectionParameters()
466
471
$ this ->assertArrayHasKey (1 , $ instance ::$ createConnectionParams );
467
472
$ createConnectionOptions = $ instance ::$ createConnectionParams [1 ];
468
473
$ this ->assertArrayHasKey ('ssl_context ' , $ createConnectionOptions );
469
- $ createConnectionContext = $ createConnectionOptions ['ssl_context ' ];
474
+ $ createConnectionContext = $ createConnectionOptions ['context ' ];
470
475
// unset to check whole array at once later
471
476
$ instance ::$ createConnectionParams [1 ]['ssl_context ' ] = null ;
477
+ $ instance ::$ createConnectionParams [1 ]['context ' ] = null ;
472
478
$ this ->assertIsResource ($ createConnectionContext );
473
479
$ this ->assertEquals ('stream-context ' , get_resource_type ($ createConnectionContext ));
474
480
$ createConnectionOptions = stream_context_get_options ($ createConnectionContext );
@@ -491,6 +497,7 @@ public function testSSLClusterConnectionParameters()
491
497
'connection_timeout ' => 3 ,
492
498
'read_write_timeout ' => 3 ,
493
499
'ssl_context ' => null ,
500
+ 'context ' => null ,
494
501
'keepalive ' => false ,
495
502
'heartbeat ' => 0 ,
496
503
]
@@ -524,6 +531,7 @@ public function testSSLClusterConnectionParameters()
524
531
'connection_timeout ' => 3 ,
525
532
'read_write_timeout ' => 3 ,
526
533
'ssl_context ' => null , // context checked earlier
534
+ 'context ' => null , // context checked earlier
527
535
'keepalive ' => false ,
528
536
'heartbeat ' => 0
529
537
]
0 commit comments