Add unit tests for Japanization and fix several bugs.

Internal issue number: 2195990
10 files changed