unknownStepRule = $unknownStepRule; $this->validStepArgsRule = $validStepArgsRule; $this->validStepFiltersRule = $validStepFiltersRule; $this->validStepOrderRule = $validStepOrderRule; $this->validStepValidationRule = $validStepValidationRule; $this->automationWalker = $automationWalker; } public function validate(Automation $automation): void { $this->automationWalker->walk($automation, [ new NoUnreachableStepsRule(), new ConsistentStepMapRule(), new NoDuplicateEdgesRule(), new TriggersUnderRootRule(), new NoCycleRule(), new NoJoinRule(), $this->unknownStepRule, new AtLeastOneTriggerRule(), new TriggerNeedsToBeFollowedByActionRule(), new ValidStepRule([ $this->validStepArgsRule, $this->validStepFiltersRule, $this->validStepOrderRule, $this->validStepValidationRule, ]), ]); } }