File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
src/Symfony/Component/Messenger/Bridge/Redis/Tests/Transport Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -412,18 +412,18 @@ public function testInvalidSentinelMasterName()
412412 $ this ->markTestSkipped ('REDIS_SENTINEL_HOSTS env var is not defined. ' );
413413 }
414414
415+ if (!getenv ('MESSENGER_REDIS_SENTINEL_MASTER ' )) {
416+ self ::markTestSkipped ('Redis sentinel is not configured ' );
417+ }
418+
415419 $ dsn = 'redis:?host[ ' .str_replace (' ' , ']&host[ ' , $ hosts ).'] ' ;
416420
417421 try {
418- Connection::fromDsn ($ dsn , ['delete_after_ack ' => true ]);
422+ Connection::fromDsn ($ dsn , ['delete_after_ack ' => true , ' sentinel_master ' => getenv ( ' MESSENGER_REDIS_SENTINEL_MASTER ' ) ]);
419423 } catch (\Exception $ e ) {
420424 self ::markTestSkipped ($ e ->getMessage ());
421425 }
422426
423- if (!getenv ('MESSENGER_REDIS_SENTINEL_MASTER ' )) {
424- self ::markTestSkipped ('Redis sentinel is not configured ' );
425- }
426-
427427 $ uid = uniqid ('sentinel_ ' , true );
428428
429429 $ this ->expectException (\InvalidArgumentException::class);
You can’t perform that action at this time.
0 commit comments