mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-28 04:58:46 +02:00
N°5608 - Use new ItopTestCase::RequireOnceXXX in unit tests
This commit is contained in:
@@ -15,7 +15,7 @@ class TwigTest extends ItopDataTestCase
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
require_once __DIR__.'/../../core/config.class.inc.php';
|
||||
$this->RequireOnceItopFile('core/config.class.inc.php');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -43,6 +43,7 @@ class TwigTest extends ItopDataTestCase
|
||||
{
|
||||
$oTwig->addFunction($oFunction);
|
||||
}
|
||||
}
|
||||
|
||||
public static function testTemplateProvider()
|
||||
{
|
||||
|
||||
@@ -92,9 +92,9 @@ class StatusIncTest extends TestCase {
|
||||
include_once($this->sAppRoot . '/status.inc.php');
|
||||
|
||||
StatusCheckConfigFile();
|
||||
require_once(APPROOT . '/core/cmdbobject.class.inc.php');
|
||||
require_once(APPROOT . '/application/utils.inc.php');
|
||||
require_once(APPROOT . '/core/contexttag.class.inc.php');
|
||||
require_once(APPROOT . '/core/cmdbobject.class.inc.php');
|
||||
require_once(APPROOT . '/application/utils.inc.php');
|
||||
require_once(APPROOT . '/core/contexttag.class.inc.php');
|
||||
|
||||
$oConfigWrong = new Config(ITOP_DEFAULT_CONFIG_FILE);
|
||||
$oConfigWrong->Set('db_pwd', $oConfigWrong->Get('db_pwd') . '_unittest');
|
||||
|
||||
Reference in New Issue
Block a user