Fixed RBAC databases tests

tests were reusing static DB connection instance resulting in all tests
to be run against MySQL only!

PgSQL and Sqlite tests are now failing because of the issue reported in #13501.
This commit is contained in:
Carsten Brandt
2017-05-31 18:52:36 +02:00
parent fa4d76223b
commit 2feb0945ca
3 changed files with 68 additions and 21 deletions

View File

@@ -0,0 +1,29 @@
<?php
namespace yiiunit\framework\rbac;
use yii\caching\FileCache;
use yii\rbac\DbManager;
/**
* PgSQLManagerTest
* @group db
* @group rbac
* @group pgsql
*/
class PgSQLManagerCacheTest extends DbManagerTestCase
{
protected static $driverName = 'pgsql';
/**
* @return \yii\rbac\ManagerInterface
*/
protected function createManager()
{
return new DbManager([
'db' => $this->getConnection(),
'cache' => new FileCache(['cachePath' => '@yiiunit/runtime/cache']),
'defaultRoles' => ['myDefaultRole']
]);
}
}