Add test for RRSIG with timestamp in epoch

This is standard's compliant but currently not supported.
This commit is contained in:
Miek Gieben 2014-01-11 08:37:34 +00:00
parent f3af5834c2
commit c174304212
2 changed files with 16 additions and 2 deletions

View File

@ -813,3 +813,18 @@ func TestDigit(t *testing.T) {
}
}
}
func TestParseRRSIGTimestamp(t *testing.T) {
tests := map[string]bool{
`miek.nl. IN RRSIG SOA 8 2 43200 20140210031301 20140111031301 12051 miek.nl. MVZUyrYwq0iZhMFDDnVXD2BvuNiUJjSYlJAgzyAE6CF875BMvvZa+Sb0 RlSCL7WODQSQHhCx/fegHhVVF+Iz8N8kOLrmXD1+jO3Bm6Prl5UhcsPx WTBsg/kmxbp8sR1kvH4oZJtVfakG3iDerrxNaf0sQwhZzyfJQAqpC7pcBoc=`: true,
// `miek.nl. IN RRSIG SOA 8 2 43200 315565800 4102477800 12051 miek.nl. MVZUyrYwq0iZhMFDDnVXD2BvuNiUJjSYlJAgzyAE6CF875BMvvZa+Sb0 RlSCL7WODQSQHhCx/fegHhVVF+Iz8N8kOLrmXD1+jO3Bm6Prl5UhcsPx WTBsg/kmxbp8sR1kvH4oZJtVfakG3iDerrxNaf0sQwhZzyfJQAqpC7pcBoc=`:true,
}
for r, _ := range tests {
_, e := NewRR(r)
if e != nil {
t.Fail()
t.Logf("%s\n", e.Error())
}
}
}

View File

@ -239,8 +239,7 @@ func endingToTxtSlice(c chan lex, errstr, f string) ([]string, *ParseError, stri
s = append(s, "")
}
quote = !quote
// TODO(miek): remove, next line
empty = quote
empty = true
default:
return nil, &ParseError{f, errstr, l}, ""
}