Fold testcase in 1 file
This commit is contained in:
parent
7d96686820
commit
30e535b495
|
@ -1,24 +0,0 @@
|
|||
package resolver
|
||||
|
||||
import (
|
||||
"testing"
|
||||
"dns"
|
||||
)
|
||||
|
||||
|
||||
func TestAXFR(t *testing.T) {
|
||||
res := new(Resolver)
|
||||
ch := res.NewXfer()
|
||||
|
||||
res.Servers = []string{"127.0.0.1"}
|
||||
m := new(dns.Msg)
|
||||
m.Question = make([]dns.Question, 1)
|
||||
m.Question[0] = dns.Question{"miek.nl", dns.TypeAXFR, dns.ClassINET}
|
||||
//m.Question[0] = dns.Question{"atoom.net", dns.TypeAXFR, dns.ClassINET}
|
||||
|
||||
ch <- Msg{m, nil}
|
||||
for dm := range ch {
|
||||
var _ = dm
|
||||
/* fmt.Printf("%v\n",dm.Dns) */
|
||||
}
|
||||
}
|
|
@ -128,3 +128,20 @@ func TestResolverTsig(t *testing.T) {
|
|||
ch <- Msg{nil, nil}
|
||||
<-ch // wait for ch to close channel
|
||||
}
|
||||
|
||||
func TestAXFR(t *testing.T) {
|
||||
res := new(Resolver)
|
||||
ch := res.NewXfer()
|
||||
|
||||
res.Servers = []string{"127.0.0.1"}
|
||||
m := new(dns.Msg)
|
||||
m.Question = make([]dns.Question, 1)
|
||||
m.Question[0] = dns.Question{"miek.nl", dns.TypeAXFR, dns.ClassINET}
|
||||
//m.Question[0] = dns.Question{"atoom.net", dns.TypeAXFR, dns.ClassINET}
|
||||
|
||||
ch <- Msg{m, nil}
|
||||
for dm := range ch {
|
||||
var _ = dm
|
||||
/* fmt.Printf("%v\n",dm.Dns) */
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue