mirror of
https://github.com/Combodo/iTop.git
synced 2026-03-09 02:54:11 +01:00
✅ ItopDataTestCase fix cached SQL queries with silo
This commit is contained in:
@@ -135,10 +135,18 @@ abstract class ItopDataTestCase extends ItopTestCase
|
||||
// Leave the place clean
|
||||
\UserRights::Logoff();
|
||||
$this->SetNonPublicStaticProperty(UserRights::class, 'm_aCacheUsers', []);
|
||||
$this->ResetMetaModelQueyCacheGetObject();
|
||||
|
||||
parent::tearDown();
|
||||
}
|
||||
|
||||
/**
|
||||
* Helper to reset the metamodel cache : for a class and a key it will contain the SQL query, that could include silo filter
|
||||
*/
|
||||
protected function ResetMetaModelQueyCacheGetObject() {
|
||||
$this->SetNonPublicStaticProperty(MetaModel::class, 'aQueryCacheGetObject', []);
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user