/** * Register Transformer. * * @param TransformerInterface $transformer Transformer */ public function registerTransformer(TransformerInterface $transformer) { $this->items[] = $transformer; $transformer->registerCustomTokens(); foreach ($transformer->getCustomTokenNames() as $name) { $this->addCustomToken(constant($name), $name); } }
/** * @dataProvider getPriorityCases */ public function testPriority(TransformerInterface $first, TransformerInterface $second) { $this->assertLessThan($first->getPriority(), $second->getPriority()); }