/** * @test */ public function I_can_register_it_and_specific_choices_by_self() { ExceptionalityChoiceType::registerAll(); self::assertTrue(Type::hasType($this->getExpectedTypeName())); self::assertTrue(ExceptionalityChoiceType::hasSubTypeEnum(Fortune::class)); self::assertTrue(ExceptionalityChoiceType::hasSubTypeEnum(PlayerDecision::class)); }
public static function registerAll() { ExceptionalityChoiceType::registerSelf(); if (!static::hasSubTypeEnum(Fortune::class)) { static::addSubTypeEnum(Fortune::class, '~^' . Fortune::FORTUNE . '$~'); } if (!static::hasSubTypeEnum(PlayerDecision::class)) { static::addSubTypeEnum(PlayerDecision::class, '~^' . PlayerDecision::PLAYER_DECISION . '$~'); } }
public static function registerAll() { ExceptionalityChoiceType::registerAll(); ExceptionalityFateType::registerAll(); PropertiesEnumRegistrar::registerAll(); }