Character fixes and unit tests