Skip to content

Commit 6d5887c

Browse files
committed
Add tests to messenger connection get for OraclePlatform
1 parent 81c9e39 commit 6d5887c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

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

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
use Doctrine\DBAL\Exception;
2020
use Doctrine\DBAL\Platforms\AbstractPlatform;
2121
use Doctrine\DBAL\Platforms\MySQL57Platform;
22+
use Doctrine\DBAL\Platforms\OraclePlatform;
2223
use Doctrine\DBAL\Platforms\SQLServer2012Platform;
2324
use Doctrine\DBAL\Query\QueryBuilder;
2425
use Doctrine\DBAL\Result;
@@ -405,5 +406,10 @@ public function providePlatformSql(): iterable
405406
new SQLServer2012Platform(),
406407
'SELECT m.* FROM messenger_messages m WITH (UPDLOCK, ROWLOCK) WHERE (m.delivered_at is null OR m.delivered_at < ?) AND (m.available_at <= ?) AND (m.queue_name = ?) ORDER BY available_at ASC OFFSET 0 ROWS FETCH NEXT 1 ROWS ONLY ',
407408
];
409+
410+
yield 'Oracle' => [
411+
new OraclePlatform(),
412+
'SELECT w.* FROM messenger_messages w WHERE w.id IN(SELECT a.id FROM (SELECT m.* FROM messenger_messages m WHERE (m.delivered_at is null OR m.delivered_at < ?) AND (m.available_at <= ?) AND (m.queue_name = ?) ORDER BY available_at ASC) a WHERE ROWNUM <= 1) FOR UPDATE',
413+
];
408414
}
409415
}

0 commit comments

Comments
 (0)