public function __construct(FixtureWithFlagsInterface $fixture) { $flags = $fixture->getFlags(); foreach ($flags as $flag) { if ($flag instanceof TemplateFlag) { $this->isATemplate = true; continue; } if ($flag instanceof ExtendFlag) { // Potential flag duplication is handled at the flagbag level array_unshift($this->extends, $flag->getExtendedFixture()); } } }
/** * @inheritdoc */ public function getFlags() : FlagBag { return $this->fixture->getFlags(); }