Skip to content

Commit

Permalink
update ModelUtilTest.php
Browse files Browse the repository at this point in the history
  • Loading branch information
ericges committed Feb 16, 2024
1 parent b7f891b commit cfb1be8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/Util/ModelUtilTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
use Contao\ContentModel;
use Contao\Controller;
use Contao\CoreBundle\Framework\Adapter;
use Contao\CoreBundle\InsertTag\InsertTagParser;
use Contao\Model;
use Contao\PageModel;
use Contao\System;
Expand All @@ -22,7 +23,6 @@
use HeimrichHannot\UtilsBundle\Util\ModelUtil;
use PHPUnit\Framework\MockObject\MockBuilder;
use PHPUnit\Framework\MockObject\MockObject;
use function Clue\StreamFilter\fun;

class ModelUtilTest extends AbstractUtilsTestCase
{
Expand All @@ -40,7 +40,9 @@ public function getTestInstance(array $parameters = [], ?MockBuilder $mockBuilde
Model::class => $this->modelAdapter,
]);

return new ModelUtil($contaoFramework);
$insertTagParser = $parameters['insertTagParser'] ?? $this->createMock(InsertTagParser::class);

return new ModelUtil($contaoFramework, $insertTagParser);
}

/**
Expand Down

0 comments on commit cfb1be8

Please sign in to comment.