Test to check that UTF-8 characters are serialized correctly