package providers import ( "testing" ) func TestGetList(t *testing.T) { want := []ProviderType{FILE, ETCD, REDIS, BADGER} arr := getList() for i, v := range arr { if v != want[i] { t.Errorf("getList() = %v, want %v", arr, &want) } } }