small fixes to make tests pass