source = new class() extends AbstractSource { }; } public function testConstructor(): void { $this->assertInstanceOf(EntityInterface::class, $this->source); $this->assertInstanceOf(RelationInterface::class, $this->source->getRelation()); $this->assertInstanceOf(Collection::class, $this->source->getMemberships()); $this->assertInstanceOf(LawInterface::class, $this->source->getLaw()); $this->assertInstanceOf(Collection::class, $this->source->getMembers()); } public function testSlugInit(): void { $this->expectException(\TypeError::class); $this->source->getSlug(); } }