Skip to content

Commit b2cc352

Browse files
committed
Skip retry exhaustion test for MongoDB adapter
1 parent fe8f2fc commit b2cc352

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/e2e/Adapter/Scopes/GeneralTests.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -898,12 +898,20 @@ public function testTransactionStateAfterKnownException(): void
898898
/**
899899
* Test that withTransaction correctly resets inTransaction state
900900
* when retries are exhausted for a generic exception.
901+
*
902+
* MongoDB's withTransaction has no retry logic, so this test
903+
* only applies to SQL-based adapters.
901904
*/
902905
public function testTransactionStateAfterRetriesExhausted(): void
903906
{
904907
/** @var Database $database */
905908
$database = $this->getDatabase();
906909

910+
if ($database->getAdapter() instanceof Mongo) {
911+
$this->expectNotToPerformAssertions();
912+
return;
913+
}
914+
907915
$attempts = 0;
908916

909917
try {

0 commit comments

Comments
 (0)