diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/StatusCommandTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/StatusCommandTest.php index 350c9dce2d..c5657ed7a4 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/StatusCommandTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/StatusCommandTest.php @@ -5,6 +5,7 @@ namespace Doctrine\Migrations\Tests\Tools\Console\Command; use DateTimeImmutable; +use Doctrine\DBAL\Version as DBALVersion; use Doctrine\Migrations\Configuration\Configuration; use Doctrine\Migrations\Configuration\Connection\ExistingConnection; use Doctrine\Migrations\Configuration\Migration\ExistingConfiguration; @@ -73,6 +74,12 @@ public function testExecute(): void $lines = array_map('trim', explode("\n", trim($this->commandTester->getDisplay(true)))); + if (DBALVersion::compare('2.11.0') > 0) { + $databaseDriver = 'Doctrine\DBAL\Driver\PDOSqlite\Driver '; // Trailing space bufferes outout assertion + } else { + $databaseDriver = 'Doctrine\DBAL\Driver\PDO\SQLite\Driver'; + } + self::assertSame( [ '+----------------------+----------------------+------------------------------------------------------------------------+', @@ -82,7 +89,7 @@ public function testExecute(): void '| | Table Name | doctrine_migration_versions |', '| | Column Name | version |', '|----------------------------------------------------------------------------------------------------------------------|', - '| Database | Driver | Doctrine\DBAL\Driver\PDOSqlite\Driver |', + '| Database | Driver | ' . $databaseDriver . ' |', '| | Name | |', '|----------------------------------------------------------------------------------------------------------------------|', '| Versions | Previous | 1230 |',