mirror of https://github.com/status-im/consul.git
Fix tests after config refactor
This commit is contained in:
parent
fa67334361
commit
abe41d231c
|
@ -394,8 +394,7 @@ func TestDNS_NodeLookup_CNAME(t *testing.T) {
|
|||
}
|
||||
|
||||
func TestDNS_NodeLookup_TXT(t *testing.T) {
|
||||
cfg := TestConfig()
|
||||
a := NewTestAgent(t.Name(), cfg)
|
||||
a := NewTestAgent(t.Name(), ``)
|
||||
defer a.Shutdown()
|
||||
|
||||
args := &structs.RegisterRequest{
|
||||
|
@ -417,8 +416,7 @@ func TestDNS_NodeLookup_TXT(t *testing.T) {
|
|||
m.SetQuestion("google.node.consul.", dns.TypeTXT)
|
||||
|
||||
c := new(dns.Client)
|
||||
addr, _ := a.Config.ClientListener("", a.Config.Ports.DNS)
|
||||
in, _, err := c.Exchange(m, addr.String())
|
||||
in, _, err := c.Exchange(m, a.DNSAddr())
|
||||
if err != nil {
|
||||
t.Fatalf("err: %v", err)
|
||||
}
|
||||
|
@ -441,8 +439,7 @@ func TestDNS_NodeLookup_TXT(t *testing.T) {
|
|||
}
|
||||
|
||||
func TestDNS_NodeLookup_ANY(t *testing.T) {
|
||||
cfg := TestConfig()
|
||||
a := NewTestAgent(t.Name(), cfg)
|
||||
a := NewTestAgent(t.Name(), ``)
|
||||
defer a.Shutdown()
|
||||
|
||||
args := &structs.RegisterRequest{
|
||||
|
@ -463,8 +460,7 @@ func TestDNS_NodeLookup_ANY(t *testing.T) {
|
|||
m.SetQuestion("bar.node.consul.", dns.TypeANY)
|
||||
|
||||
c := new(dns.Client)
|
||||
addr, _ := a.Config.ClientListener("", a.Config.Ports.DNS)
|
||||
in, _, err := c.Exchange(m, addr.String())
|
||||
in, _, err := c.Exchange(m, a.DNSAddr())
|
||||
if err != nil {
|
||||
t.Fatalf("err: %v", err)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue