2018-05-25 16:19:12 +02:00
|
|
|
<?php
|
2019-12-07 12:13:32 +01:00
|
|
|
|
2019-08-12 17:25:59 +02:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
2019-12-01 12:16:06 +01:00
|
|
|
namespace TTN\Tea\Tests\Unit\Domain\Repository\Product;
|
2018-05-25 16:19:12 +02:00
|
|
|
|
|
|
|
use Nimut\TestingFramework\TestCase\UnitTestCase;
|
|
|
|
use Prophecy\Prophecy\ProphecySubjectInterface;
|
2019-12-07 17:44:32 +01:00
|
|
|
use TTN\Tea\Domain\Repository\Product\TeaRepository;
|
2018-05-25 16:19:12 +02:00
|
|
|
use TYPO3\CMS\Extbase\Object\ObjectManagerInterface;
|
|
|
|
use TYPO3\CMS\Extbase\Persistence\Repository;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Test case.
|
|
|
|
*
|
|
|
|
* @author Oliver Klee <typo3-coding@oliverklee.de
|
|
|
|
*/
|
|
|
|
class TeaRepositoryTest extends UnitTestCase
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @var TeaRepository
|
|
|
|
*/
|
|
|
|
private $subject = null;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var ObjectManagerInterface|ProphecySubjectInterface
|
|
|
|
*/
|
|
|
|
protected $objectManager = null;
|
|
|
|
|
2019-08-12 17:25:59 +02:00
|
|
|
protected function setUp(): void
|
2018-05-25 16:19:12 +02:00
|
|
|
{
|
2019-08-12 17:43:02 +02:00
|
|
|
$this->objectManager = $this->prophesize(ObjectManagerInterface::class)->reveal();
|
2018-05-25 16:19:12 +02:00
|
|
|
$this->subject = new TeaRepository($this->objectManager);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @test
|
|
|
|
*/
|
2019-08-12 17:25:59 +02:00
|
|
|
public function isRepository(): void
|
2018-05-25 16:19:12 +02:00
|
|
|
{
|
2019-08-12 17:25:59 +02:00
|
|
|
self::assertInstanceOf(Repository::class, $this->subject);
|
2018-05-25 16:19:12 +02:00
|
|
|
}
|
|
|
|
}
|