aboutsummaryrefslogtreecommitdiff
path: root/plugin/pkg/parse/host_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/pkg/parse/host_test.go')
-rw-r--r--plugin/pkg/parse/host_test.go20
1 files changed, 20 insertions, 0 deletions
diff --git a/plugin/pkg/parse/host_test.go b/plugin/pkg/parse/host_test.go
index f6e771f29..1c23c5bee 100644
--- a/plugin/pkg/parse/host_test.go
+++ b/plugin/pkg/parse/host_test.go
@@ -34,6 +34,26 @@ func TestHostPortOrFile(t *testing.T) {
"127.0.0.1:53",
false,
},
+ {
+ "fe80::1",
+ "[fe80::1]:53",
+ false,
+ },
+ {
+ "fe80::1%ens3",
+ "[fe80::1%ens3]:53",
+ false,
+ },
+ {
+ "[fd01::1]:153",
+ "[fd01::1]:153",
+ false,
+ },
+ {
+ "[fd01::1%ens3]:153",
+ "[fd01::1%ens3]:153",
+ false,
+ },
}
err := ioutil.WriteFile("resolv.conf", []byte("nameserver 127.0.0.1\n"), 0600)