mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-21 01:28:47 +02:00
N°931 fix requirements for AttributeTagSet PhpUnit tests
* itop-kown-error-mgmt module * creates a FAQCategory if needed
This commit is contained in:
@@ -498,9 +498,17 @@ class ItopDataTestCase extends ItopTestCase
|
||||
|
||||
protected function CreateObjectWithTagSet()
|
||||
{
|
||||
$oFaqCategory = MetaModel::GetObject('FAQCategory', 1, false);
|
||||
if (empty($oFaqCategory))
|
||||
{
|
||||
$oFaqCategory = $this->createObject('FAQCategory', array(
|
||||
'name' => 'FAQCategory_phpunit',
|
||||
));
|
||||
}
|
||||
|
||||
/** @var FAQ $oFaq */
|
||||
$oFaq = $this->createObject('FAQ', array(
|
||||
'category_id' => 1,
|
||||
'category_id' => $oFaqCategory->GetKey(),
|
||||
'title' => 'FAQ_phpunit',
|
||||
));
|
||||
$this->debug("Created {$oFaq->GetName()}");
|
||||
|
||||
Reference in New Issue
Block a user