several tests fixes