Commit 0b09e501 authored by romanb's avatar romanb

[2.0] Adjusted getConnection since there is no need to create/drop the...

[2.0] Adjusted getConnection since there is no need to create/drop the database for sqlite in-memory.
parent c3f5cba7
...@@ -16,18 +16,17 @@ class TestUtil ...@@ -16,18 +16,17 @@ class TestUtil
'dbname' => $GLOBALS['db_name'], 'dbname' => $GLOBALS['db_name'],
'port' => $GLOBALS['db_port'] 'port' => $GLOBALS['db_port']
); );
$conn = \Doctrine\DBAL\DriverManager::getConnection($params);
$conn->getSchemaManager()->dropAndCreateDatabase();
$conn->close();
$conn->connect();
} else { } else {
$params = array( $params = array(
'driver' => 'pdo_sqlite', 'driver' => 'pdo_sqlite',
'memory' => true 'memory' => true
); );
}
$conn = \Doctrine\DBAL\DriverManager::getConnection($params); $conn = \Doctrine\DBAL\DriverManager::getConnection($params);
$conn->getSchemaManager()->dropAndCreateDatabase(); }
$conn->close();
$conn->connect();
return $conn; return $conn;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment