mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
Work around extra whitespace in spf records (#361)
* handle empty spf parts from bad records * update spf tool
This commit is contained in:
@ -27,3 +27,15 @@ func TestParse(t *testing.T) {
|
||||
}
|
||||
t.Log(rec.Print())
|
||||
}
|
||||
|
||||
func TestParseWithDoubleSpaces(t *testing.T) {
|
||||
dnsres, err := NewCache("testdata-dns1.json")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
rec, err := Parse("v=spf1 ip4:192.111.0.0/24 ip4:192.111.1.0/24 -all", dnsres)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(rec.Print())
|
||||
}
|
||||
|
Reference in New Issue
Block a user