use PHPUnit\Framework\TestCase;
use Symfony\Component\Form\Exception\TransformationFailedException;
use Symfony\Component\Form\Extension\Core\DataTransformer\ValueToDuplicatesTransformer;
class ValueToDuplicatesTransformerTest extends TestCase
{ private ValueToDuplicatesTransformer
$transformer;
protected function setUp(): void
{ $this->transformer =
new ValueToDuplicatesTransformer(['a', 'b', 'c'
]);
} public function testTransform() { $output =
[ 'a' => 'Foo',
'b' => 'Foo',
'c' => 'Foo',
];
$this->
assertSame($output,
$this->transformer->
transform('Foo'
));
}