diff --git a/Classes/Core/Testbase.php b/Classes/Core/Testbase.php index a175bd97..7b40adf1 100644 --- a/Classes/Core/Testbase.php +++ b/Classes/Core/Testbase.php @@ -659,9 +659,10 @@ public function setUpTestDatabase(string $databaseName, string $originalDatabase // @todo: This should by now work with using "our" ConnectionPool again, it does now, though. $connectionParameters = $GLOBALS['TYPO3_CONF_VARS']['DB']['Connections']['Default']; unset($connectionParameters['dbname']); - $schemaManager = DriverManager::getConnection($connectionParameters)->createSchemaManager(); + $connection = DriverManager::getConnection($connectionParameters); + $schemaManager = $connection->createSchemaManager(); - if ($schemaManager->getDatabasePlatform()->getName() === 'sqlite') { + if ($connection->getDatabasePlatform()->getName() === 'sqlite') { // This is the "path" option in sqlite: one file = one db $schemaManager->dropDatabase($databaseName); } elseif (in_array($databaseName, $schemaManager->listDatabases(), true)) {