more fixes to unit tests