Skip to content

Commit

Permalink
Iterable
Browse files Browse the repository at this point in the history
  • Loading branch information
AdrienClairembault committed Oct 10, 2022
1 parent d1ba273 commit 62a597f
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions tests/functionnal/KnowbaseItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
namespace test\units;

use DbTestCase;
use Generator;
use Glpi\Toolbox\Sanitizer;

/* Test for inc/knowbaseitem.class.php */
Expand Down Expand Up @@ -510,13 +509,13 @@ public function testCreateWithCategories()
$this->array($category_ids)->containsValues([$kb_cat_id1, $kb_cat_id2]);
}

protected function testGetVisibilityCriteriaProvider(): Generator
protected function testGetVisibilityCriteriaProvider(): iterable
{
yield from $this->testGetVisibilityCriteriaProvider_FAQ();
yield from $this->testGetVisibilityCriteriaProvider_KB();
}

protected function testGetVisibilityCriteriaProvider_FAQ(): Generator
protected function testGetVisibilityCriteriaProvider_FAQ(): iterable
{
global $DB, $CFG_GLPI;

Expand Down Expand Up @@ -573,7 +572,7 @@ protected function testGetVisibilityCriteriaProvider_FAQ(): Generator
$CFG_GLPI['use_public_faq'] = false;
}

protected function testGetVisibilityCriteriaProvider_KB(): Generator
protected function testGetVisibilityCriteriaProvider_KB(): iterable
{
// Create set of test subjects
$glpi_user = getItemByTypeName("User", "glpi", true);
Expand Down

0 comments on commit 62a597f

Please sign in to comment.