Add a test for InternalBallotsNormalizer.
Fix bug and improve tests.