private static function buildConnection($connection) { if ($connection instanceof \PDO) { $connection = new Connection($connection); } elseif (is_array($connection)) { $connection = Connection::make($connection); } elseif (!$connection instanceof Connection) { throw new \InvalidArgumentException("Argument must be an instance of PDO, DbSync\\Connection or a valid connection config array"); } return $connection; }
public function setUp() { $this->utilityDb = \DbSync\Connection::make(include __DIR__ . '/config.php'); $this->createTestDatabases(); }
/** * */ public function quote($value) { return $this->_connection->quote($value); }