Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit cdcb6c9

Browse filesBrowse files
committed
made error message more clear
1 parent fba11b4 commit cdcb6c9
Copy full SHA for cdcb6c9

File tree

5 files changed

+8
-8
lines changed
Filter options

5 files changed

+8
-8
lines changed

‎src/Symfony/Component/Messenger/Tests/Transport/Doctrine/DoctrineTransportFactoryTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Messenger/Tests/Transport/Doctrine/DoctrineTransportFactoryTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public function testCreateTransport()
5151

5252
/**
5353
* @expectedException \Symfony\Component\Messenger\Exception\TransportException
54-
* @expectedExceptionMessage Could not find Doctrine connection from DSN "doctrine://default".
54+
* @expectedExceptionMessage Could not find Doctrine connection from Messenger DSN "doctrine://default".
5555
*/
5656
public function testCreateTransportMustThrowAnExceptionIfManagerIsNotFound()
5757
{

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

Copy file name to clipboardExpand all lines: src/Symfony/Component/Messenger/Transport/Doctrine/Connection.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ public function getConfiguration(): array
6868
public static function buildConfiguration($dsn, array $options = [])
6969
{
7070
if (false === $components = parse_url($dsn)) {
71-
throw new InvalidArgumentException(sprintf('The given Doctrine DSN "%s" is invalid.', $dsn));
71+
throw new InvalidArgumentException(sprintf('The given Doctrine Messenger DSN "%s" is invalid.', $dsn));
7272
}
7373

7474
$query = [];

‎src/Symfony/Component/Messenger/Transport/Doctrine/DoctrineTransportFactory.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Messenger/Transport/Doctrine/DoctrineTransportFactory.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public function createTransport(string $dsn, array $options, SerializerInterface
3838
try {
3939
$driverConnection = $this->registry->getConnection($configuration['connection']);
4040
} catch (\InvalidArgumentException $e) {
41-
throw new TransportException(sprintf('Could not find Doctrine connection from DSN "%s".', $dsn), 0, $e);
41+
throw new TransportException(sprintf('Could not find Doctrine connection from Messenger DSN "%s".', $dsn), 0, $e);
4242
}
4343

4444
$connection = new Connection($configuration, $driverConnection);

‎src/Symfony/Component/Messenger/Transport/Sync/SyncTransport.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Messenger/Transport/Sync/SyncTransport.php
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,22 @@ class SyncTransport implements TransportInterface
2727
{
2828
public function get(): iterable
2929
{
30-
throw new InvalidArgumentException('You cannot receive messages from the SyncTransport.');
30+
throw new InvalidArgumentException('You cannot receive messages from the Messenger SyncTransport.');
3131
}
3232

3333
public function stop(): void
3434
{
35-
throw new InvalidArgumentException('You cannot call stop() on the SyncTransport.');
35+
throw new InvalidArgumentException('You cannot call stop() on the Messenger SyncTransport.');
3636
}
3737

3838
public function ack(Envelope $envelope): void
3939
{
40-
throw new InvalidArgumentException('You cannot call ack() on the SyncTransport.');
40+
throw new InvalidArgumentException('You cannot call ack() on the Messenger SyncTransport.');
4141
}
4242

4343
public function reject(Envelope $envelope): void
4444
{
45-
throw new InvalidArgumentException('You cannot call reject() on the SyncTransport.');
45+
throw new InvalidArgumentException('You cannot call reject() on the Messenger SyncTransport.');
4646
}
4747

4848
public function send(Envelope $envelope): Envelope

‎src/Symfony/Component/Messenger/Transport/TransportFactory.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Messenger/Transport/TransportFactory.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public function createTransport(string $dsn, array $options, SerializerInterface
3939
}
4040
}
4141

42-
throw new InvalidArgumentException(sprintf('No transport supports the given DSN "%s".', $dsn));
42+
throw new InvalidArgumentException(sprintf('No transport supports the given Messenger DSN "%s".', $dsn));
4343
}
4444

4545
public function supports(string $dsn, array $options): bool

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.