mirror of https://github.com/status-im/consul.git
test: Shutdown half-started agent before retrying
This commit is contained in:
parent
584693482d
commit
8c1a668481
|
@ -140,6 +140,7 @@ func (a *TestAgent) Start() *TestAgent {
|
|||
|
||||
// retry with different ports on port conflict
|
||||
if strings.Contains(err.Error(), "bind: address already in use") {
|
||||
a.Agent.Shutdown()
|
||||
pickRandomPorts(a.Config)
|
||||
r.Fatal("port conflict")
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue