Improved toStrings and logs. Fixed test.