Skip to content

Commit efd3b30

Browse files
committed
Fix precendence in 4.4
1 parent 055dd28 commit efd3b30

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

src/Symfony/Component/Messenger/Tests/Transport/Doctrine/ConnectionTest.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,16 @@ public function buildConfigurationProvider(): iterable
243243
'expectedQueue' => 'default',
244244
'expectedAutoSetup' => true,
245245
];
246+
247+
yield 'options from dsn overrideoptions' => [
248+
'dsn' => 'doctrine://default?table_name=name_from_dsn',
249+
'options' => ['table_name' => 'name_from_options'],
250+
'expectedConnection' => 'default',
251+
'expectedTableName' => 'name_from_dsn',
252+
'expectedRedeliverTimeout' => 3600,
253+
'expectedQueue' => 'default',
254+
'expectedAutoSetup' => false,
255+
];
246256
}
247257

248258
public function testItThrowsAnExceptionIfAnExtraOptionsInDefined()

src/Symfony/Component/Messenger/Transport/Doctrine/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public static function buildConfiguration(string $dsn, array $options = []): arr
8585
}
8686

8787
$configuration = ['connection' => $components['host']];
88-
$configuration += $options + $query + self::DEFAULT_OPTIONS;
88+
$configuration += $query + $options + self::DEFAULT_OPTIONS;
8989

9090
$configuration['auto_setup'] = filter_var($configuration['auto_setup'], FILTER_VALIDATE_BOOLEAN);
9191

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy