More elegant translation and associated tests