mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
Optimized for SPA
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Unit\Entity\Attribut;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use App\Entity\Attribut\LayerAttributInterface;
|
||||
use App\Entity\Attribut\LayerAttribut;
|
||||
use App\DBAL\Types\Meta\Right\LayerType;
|
||||
|
||||
class LayerAttributTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* @var LayerAttributInterface
|
||||
*/
|
||||
protected $layer;
|
||||
|
||||
public function setUp(): void
|
||||
{
|
||||
$this->layer = new class() implements LayerAttributInterface {
|
||||
use LayerAttribut;
|
||||
};
|
||||
}
|
||||
|
||||
public function testConstruct(): void
|
||||
{
|
||||
$this->expectException(\TypeError::class);
|
||||
$this->layer->getLayer();
|
||||
}
|
||||
|
||||
public function testAccessors(): void
|
||||
{
|
||||
foreach (LayerType::getChoices() as $value) {
|
||||
$this->assertNull($this->layer->setLayer($value));
|
||||
$this->assertEquals($value, $this->layer->getLayer());
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user