you have a problem in the way you try to write the test. So the test should be fixed, not the code.

and btw, with the NormalizerFormatter, ``$record['formatted']`` will be an array, so it should be the third argument, no ?