Phalcon\Test\Cache\Backend\DatabaseTest::getBackend PHP Method

getBackend() protected method

protected getBackend ( $prefix = '' )
    protected function getBackend($prefix = '')
    {
        $frontend = new CacheFrontend(['lifetime' => 10]);
        $connection = new DbAdapter(['host' => TEST_DB_HOST, 'username' => TEST_DB_USER, 'password' => TEST_DB_PASSWD, 'dbname' => TEST_DB_NAME, 'charset' => TEST_DB_CHARSET, 'port' => TEST_DB_PORT]);
        return new CacheBackend($frontend, ['db' => $connection, 'table' => 'cache_data', 'prefix' => $prefix]);
    }