open-consul/agent/retry_join_test.go
Frank Schroeder 68e8f3d0f7 agent: use github.com/hashicorp/go-discover
Replace the provider specific node discovery code
with go-discover to support AWS, Azure and GCE.

Fixes #3282
2017-08-01 11:41:43 +02:00

19 lines
417 B
Go

package agent
import (
"reflect"
"testing"
discover "github.com/hashicorp/go-discover"
)
// if this test fails check the _ imports of go-discover/provider/* packages
// in retry_join.go
func TestGoDiscoverRegistration(t *testing.T) {
got := discover.ProviderNames()
want := []string{"aws", "azure", "gce"}
if !reflect.DeepEqual(got, want) {
t.Fatalf("got go-discover providers %v want %v", got, want)
}
}