Commit Graph

8 Commits

Author SHA1 Message Date
Ludovic Fernandez 906238edc6 fix: panicing on options parsing. (#642) 2018-03-01 06:22:09 -08:00
Marc Ende 5ec0c6d20f Modified clientconfig to match ndots0 (#590)
* Modified clientconfig to match ndots0

* Added Tests for reading resolv.conf

* Cleaned up and removed duplicated code in test

* Added test for ndots below 0

* Cleaned up test

* Clean up
2017-11-27 11:17:45 +00:00
sarneaud ca092a4398 Allow parsing resolv.conf from io.Reader (#532)
* Allow parsing resolv.conf from io.Reader

This allows projects that use this parser to write unit tests without
writing temporary files to the filesystem.

* Avoid allocation by using strings.NewReader
2017-10-15 16:18:44 +02:00
James Hartig 672033dedc Added NameList function to ClientConfig (#452) 2017-02-13 20:16:50 +00:00
Miek Gieben f520760857 Lowercase all error msg from the tests 2015-11-26 14:12:38 +00:00
Michael Haro 7f051930ff Use %v as the format arg for errors 2015-02-26 00:49:59 -08:00
Miek Gieben dfa09b604c Very small cleanups 2015-02-04 06:55:03 +00:00
Yann Kerhervé 80d2db2e86 Fix ignored last line of resolv.conf
When ClientConfigFromFile is given a file that is missing a newline
before EOF, then the last directive is completely ignored.

This also adds a very basic test for a normal resolv.conf parsing.
2015-02-03 16:27:39 -08:00