textAttribut = new class() implements TextAttributInterface { use TextAttribut; }; } public function testConstructor(): void { $this->expectException(\TypeError::class); $this->textAttribut->getText(); } public function testAccessors(): void { $text = 'Hello World!'; $this->assertNull($this->textAttribut->setText($text)); $this->assertEquals($text, $this->textAttribut->getText()); } }