namespace Symfony\Component\Form\Tests\Extension\Core\DataTransformer;
use PHPUnit\Framework\TestCase;
use Symfony\Component\Form\Extension\Core\DataTransformer\DataTransformerChain;
use Symfony\Component\Form\Tests\Fixtures\FixedDataTransformer;
class DataTransformerChainTest extends TestCase
{ public function testTransform() { $chain =
new DataTransformerChain([ new FixedDataTransformer(['foo' => 'bar'
]),
new FixedDataTransformer(['bar' => 'baz'
]),
]);
$this->
assertEquals('baz',
$chain->
transform('foo'
));
} public function testReverseTransform() { $chain =
new DataTransformerChain([ new FixedDataTransformer(['baz' => 'bar'
]),