/**
  * parse and add rules to transition specification
  *
  * @param array $transitionDescription
  */
 protected function addRulesToTransitionSpecification($transitionDescription)
 {
     if (array_key_exists('rules', $transitionDescription)) {
         $rules = RulesFactory::createBatchByShortNames($transitionDescription['rules']);
         $this->getTransitionSpecification()->setRules($rules);
     }
 }
 /**
  * Создать Property содержащее правила
  *
  * @param $name
  * @param $rules
  * @return Property
  */
 protected static function createLeafProperty($name, $rules)
 {
     $property = new Property($name);
     $property->setRules(RulesFactory::createBatchByShortNames($rules));
     return $property;
 }
 public function testConvertToConfiguredRuleConfigNeedConvert()
 {
     $rules = ['greaterThen', 'lessThen'];
     $convertedRules = RulesFactory::convertToAssocRuleConfig($rules);
     $this->assertEquals([['greaterThen' => null], ['lessThen' => null]], $convertedRules, 'need to convert');
 }