fix deadlocking test