Encoding test fixed