synchronizing on dirPoll and fix test