mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
Renamed TypeAttribut to CrudAttribut
This commit is contained in:
@@ -3,36 +3,36 @@
|
||||
namespace Tests\Unit\Entity\Attribut;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use App\Entity\Attribut\TypeAttributInterface;
|
||||
use App\Entity\Attribut\TypeAttribut;
|
||||
use App\Entity\Attribut\CrudAttributInterface;
|
||||
use App\Entity\Attribut\CrudAttribut;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
class TypeAttributTest extends TestCase
|
||||
class CrudAttributTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* @var TypeAttributInterface
|
||||
* @var CrudAttributInterface
|
||||
*/
|
||||
protected $typeAttribut;
|
||||
|
||||
public function setUp(): void
|
||||
{
|
||||
$this->typeAttribut = new class() implements TypeAttributInterface {
|
||||
use TypeAttribut;
|
||||
$this->typeAttribut = new class() implements CrudAttributInterface {
|
||||
use CrudAttribut;
|
||||
};
|
||||
}
|
||||
|
||||
public function testConstructor(): void
|
||||
{
|
||||
$this->expectException(\TypeError::class);
|
||||
$this->typeAttribut->getType();
|
||||
$this->typeAttribut->getCrud();
|
||||
}
|
||||
|
||||
public function testAccessors(): void
|
||||
{
|
||||
$type = 'Hello World!';
|
||||
$this->assertNull($this->typeAttribut->setType($type));
|
||||
$this->assertEquals($type, $this->typeAttribut->getType());
|
||||
$this->assertNull($this->typeAttribut->setCrud($type));
|
||||
$this->assertEquals($type, $this->typeAttribut->getCrud());
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user