kafka-1390; TestUtils.waitUntilLeaderIsElectedOrChanged may wait longer than it needs; patched by Jun Rao; reviewed by Guozhang Wang