Commit Graph

14 Commits

Author SHA1 Message Date
Miek Gieben
388f6eea29
Tests updates (#556)
Use :0 for loopback testing. This is more portable between testing environments.
Add testRR that calls NewRR and throws error away - apply it everywhere where needed.

It seems only Go 1.9 can deal with :0 being used. Disable 1.8 in travis.
2017-11-08 10:01:19 +00:00
Miek Gieben
348c84f37e
Test: remove all Logf/Log (#547)
Move some of them to Errorf and friends, but most of them are just
gone: This make go test -v actually readable.

Remove a bunch of test that used ipv6 on localhost as this does not work
on Travis.
2017-11-03 15:50:01 +00:00
Richard Gibson
21314e1838 Fix TXT RDATA parsing (#421)
* Test for proper parsing of whitespace-separated (TXT) character-strings

* Properly parse whitespace-separated (TXT) character-strings

* Remove non-RFC treatment of backslash sequences in character-strings

Fixes gh-420

* For tests, remove non-RFC treatment of backslashes in domain names
2016-12-02 09:34:49 +00:00
Michael Haro
1be7320498 Use t.Errorf in tests and make the error variable naming more consistent. (#367)
* Make the error variable always named err.

Sometimes the error variable was named 'err' sometimes 'e'.  Sometimes
'e' refered to an EDNS or string and not an error type.

* Use t.Errorf instead of t.Logf & t.Fail.
2016-06-09 07:00:08 +01:00
shawnps
0cea3842b9 gofmt -s 2016-01-22 08:44:49 -08:00
Miek Gieben
fb82119b66 less memory use 2015-08-31 16:48:28 +01:00
Miek Gieben
0206070abf Address commments from Alex 2015-08-26 14:13:14 +01:00
Miek Gieben
6cf1a0db58 fmt 2015-08-26 12:19:38 +01:00
Miek Gieben
ac493072c7 Correctly handle CNAME/DNAMEs 2015-08-26 12:19:22 +01:00
Miek Gieben
e1d5f172ae More tests 2015-08-26 11:26:45 +01:00
Miek Gieben
0ce87cb3da More and better tests 2015-08-26 07:34:51 +01:00
Miek Gieben
fba9ecdf79 Rework a little and more tests 2015-08-25 22:35:10 +01:00
Miek Gieben
4bca364480 Cleanup the tests and add some doc string 2015-08-25 08:39:43 +01:00
Miek Gieben
79547a0341 Add Dedup function
Add function that dedups a list of RRs. Work on strings, which
adds garbage, but seems to be the least intrusive and takes the
last amount of memory.

Some fmt changes snook in as well.
2015-08-24 22:02:57 +01:00