aboutsummaryrefslogtreecommitdiff
path: root/plugin/pkg/variables/variables_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/pkg/variables/variables_test.go')
-rw-r--r--plugin/pkg/variables/variables_test.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugin/pkg/variables/variables_test.go b/plugin/pkg/variables/variables_test.go
index 939add323..e0ff64c19 100644
--- a/plugin/pkg/variables/variables_test.go
+++ b/plugin/pkg/variables/variables_test.go
@@ -5,6 +5,8 @@ import (
"testing"
"github.com/coredns/coredns/plugin/test"
+ "github.com/coredns/coredns/request"
+
"github.com/miekg/dns"
)
@@ -63,8 +65,9 @@ func TestGetValue(t *testing.T) {
m := new(dns.Msg)
m.SetQuestion("example.com.", dns.TypeA)
m.Question[0].Qclass = dns.ClassINET
+ state := request.Request{W: &test.ResponseWriter{}, Req: m}
- value, err := GetValue(tc.varName, &test.ResponseWriter{}, m)
+ value, err := GetValue(state, tc.varName)
if tc.shouldErr && err == nil {
t.Errorf("Test %d: Expected error, but didn't recieve", i)