integration/cluster.go
func checkLeaderTransition(m *member, oldLead uint64) uint64 {
	interval := time.Duration(m.s.Cfg.TickMs) * time.Millisecond
	for m.s.Lead() == 0 || (m.s.Lead() == oldLead) {
		time.Sleep(interval)
	}
	return m.s.Lead()
}
func checkLeaderTransition(m *member, oldLead uint64) uint64 {
	interval := time.Duration(m.s.Cfg.TickMs) * time.Millisecond
	for m.s.Lead() == 0 || (m.s.Lead() == oldLead) {
		time.Sleep(interval)
	}
	return m.s.Lead()
}
func checkLeaderTransition ( m * member , oldLead uint64 ) uint64 { interval := time . Duration ( m . s . Cfg . TickMs ) * time . Millisecond for m . s . Lead ( ) == 0 || ( m . s . Lead ( ) == oldLead ) { time . Sleep ( interval ) } return m . s . Lead ( ) }
// checkLeaderTransition waits for leader transition, returning the new leader ID.
checkLeaderTransition waits for leader transition returning the new leader ID .