diff options
author | 2018-04-20 11:01:06 +0100 | |
---|---|---|
committer | 2018-04-20 11:01:06 +0100 | |
commit | 8722336fff479e00900e3299f31063a9d1a76e9a (patch) | |
tree | deb3d99aeae1d8543a3dbfd20bc36b4ef7daff1b /plugin/file | |
parent | 61726b3721b6049f436841fe4c5f7db48d5a39d0 (diff) | |
download | coredns-8722336fff479e00900e3299f31063a9d1a76e9a.tar.gz coredns-8722336fff479e00900e3299f31063a9d1a76e9a.tar.zst coredns-8722336fff479e00900e3299f31063a9d1a76e9a.zip |
global: move to context (#1699)
* global: move to context
Move from golang.org/x/net/context to std lib's context.
Change done with:
for i in $(grep -l '/context' **/*.go); do sed -e 's|golang.org/x/net/context|context|' -i $i; echo $i; done
for i in **/*.go; do goimports -w $i; done
* drop from dns.pb.go as well
Diffstat (limited to 'plugin/file')
-rw-r--r-- | plugin/file/cname_test.go | 3 | ||||
-rw-r--r-- | plugin/file/delegation_test.go | 3 | ||||
-rw-r--r-- | plugin/file/dname_test.go | 3 | ||||
-rw-r--r-- | plugin/file/dnssec_test.go | 3 | ||||
-rw-r--r-- | plugin/file/ds_test.go | 3 | ||||
-rw-r--r-- | plugin/file/ent_test.go | 3 | ||||
-rw-r--r-- | plugin/file/file.go | 3 | ||||
-rw-r--r-- | plugin/file/glue_test.go | 3 | ||||
-rw-r--r-- | plugin/file/lookup_test.go | 3 | ||||
-rw-r--r-- | plugin/file/wildcard_test.go | 3 | ||||
-rw-r--r-- | plugin/file/xfr.go | 3 |
11 files changed, 22 insertions, 11 deletions
diff --git a/plugin/file/cname_test.go b/plugin/file/cname_test.go index 1dcc491ae..8721cfed6 100644 --- a/plugin/file/cname_test.go +++ b/plugin/file/cname_test.go @@ -8,8 +8,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/upstream" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) func TestLookupCNAMEChain(t *testing.T) { diff --git a/plugin/file/delegation_test.go b/plugin/file/delegation_test.go index 0685cc513..e084e1c5a 100644 --- a/plugin/file/delegation_test.go +++ b/plugin/file/delegation_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var delegationTestCases = []test.Case{ diff --git a/plugin/file/dname_test.go b/plugin/file/dname_test.go index ebb0780a0..5e4f8be99 100644 --- a/plugin/file/dname_test.go +++ b/plugin/file/dname_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) // RFC 6672, Section 2.2. Assuming QTYPE != DNAME. diff --git a/plugin/file/dnssec_test.go b/plugin/file/dnssec_test.go index eb6374b03..fb3ca05ab 100644 --- a/plugin/file/dnssec_test.go +++ b/plugin/file/dnssec_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var dnssecTestCases = []test.Case{ diff --git a/plugin/file/ds_test.go b/plugin/file/ds_test.go index 537d47def..645cdbd82 100644 --- a/plugin/file/ds_test.go +++ b/plugin/file/ds_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var dsTestCases = []test.Case{ diff --git a/plugin/file/ent_test.go b/plugin/file/ent_test.go index 124b4688b..558fe7d97 100644 --- a/plugin/file/ent_test.go +++ b/plugin/file/ent_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var entTestCases = []test.Case{ diff --git a/plugin/file/file.go b/plugin/file/file.go index d6804e124..1fd5737c1 100644 --- a/plugin/file/file.go +++ b/plugin/file/file.go @@ -9,8 +9,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/log" "github.com/coredns/coredns/request" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) type ( diff --git a/plugin/file/glue_test.go b/plugin/file/glue_test.go index bf523a90b..29744f043 100644 --- a/plugin/file/glue_test.go +++ b/plugin/file/glue_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) // another personal zone (helps in testing as my secondary is NSD diff --git a/plugin/file/lookup_test.go b/plugin/file/lookup_test.go index dd922c1b6..d75157369 100644 --- a/plugin/file/lookup_test.go +++ b/plugin/file/lookup_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var dnsTestCases = []test.Case{ diff --git a/plugin/file/wildcard_test.go b/plugin/file/wildcard_test.go index b7cc67f53..e90f833e1 100644 --- a/plugin/file/wildcard_test.go +++ b/plugin/file/wildcard_test.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/dnstest" "github.com/coredns/coredns/plugin/test" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) var wildcardTestCases = []test.Case{ diff --git a/plugin/file/xfr.go b/plugin/file/xfr.go index 4b74dd1e5..0ee985eb9 100644 --- a/plugin/file/xfr.go +++ b/plugin/file/xfr.go @@ -7,8 +7,9 @@ import ( "github.com/coredns/coredns/plugin/pkg/log" "github.com/coredns/coredns/request" + "context" + "github.com/miekg/dns" - "golang.org/x/net/context" ) // Xfr serves up an AXFR. |