Implemented collection attribut for abstract source collection and tests

This commit is contained in:
Kevin Frantz
2018-11-02 20:37:23 +01:00
parent cbb8bc702c
commit b11b53884b
3 changed files with 32 additions and 2 deletions

View File

@@ -0,0 +1,27 @@
<?php
namespace Tests\Unit\Entity\Source\Collection;
use PHPUnit\Framework\TestCase;
use App\Entity\Source\Collection\CollectionSourceInterface;
use App\Entity\Source\Collection\AbstractCollectionSource;
class AbstractCollectionSourceTest extends TestCase
{
/**
* @var CollectionSourceInterface
*/
public $collectionSource;
public function setUp(): void
{
$this->collectionSource = new class() extends AbstractCollectionSource {
};
}
public function testConstruct(): void
{
$this->expectException(\TypeError::class);
$this->collectionSource->getCollection();
}
}