fixed some (not all) errors in test