Tweaks the agent leave test to patch an occasional local failure.

pull/2815/head
James Phillips 8 years ago
parent 7d011d7d77
commit 3f3889022e
No known key found for this signature in database
GPG Key ID: 77183E682AC5FC11

@ -1,11 +1,9 @@
package api
import (
"io"
"io/ioutil"
"strings"
"testing"
"time"
"github.com/hashicorp/consul/testutil"
@ -613,7 +611,7 @@ func TestAgent_Leave(t *testing.T) {
// We sometimes see an EOF response to this one, depending on timing.
err := c2.Agent().Leave()
if err != nil && err != io.EOF {
if err != nil && !strings.Contains(err.Error(), "EOF") {
t.Fatalf("err: %v", err)
}

Loading…
Cancel
Save