Files
yii2/tests/framework/rbac/SqliteManagerTest.php
SilverFire - Dmitry Naumenko 993eb5dcf8 Fixed RBAC tests
Before the fix, in case when RBAC tests for PgSQL and MySQL are runed
in same process sequentially, the second one reused old DB connection
creating mess in DBMS. Ha, see the rhyme: Creating mess in DBMS. :D
2017-10-31 22:00:36 +02:00

32 lines
658 B
PHP

<?php
/**
* @link http://www.yiiframework.com/
* @copyright Copyright (c) 2008 Yii Software LLC
* @license http://www.yiiframework.com/license/
*/
namespace yiiunit\framework\rbac;
/**
* SqliteManagerTest.
* @group db
* @group rbac
* @group sqlite
*/
class SqliteManagerTest extends DbManagerTestCase
{
protected static $driverName = 'sqlite';
protected static $sqliteDb;
public static function createConnection()
{
// sqlite db is in memory so it can not be reused
if (static::$sqliteDb === null) {
static::$sqliteDb = parent::createConnection();
}
return static::$sqliteDb;
}
}