add missing test

This commit is contained in:
Chris Cooper 2016-02-09 10:49:41 -05:00
parent a2533d5d76
commit 1327d9eff6
1 changed files with 7 additions and 0 deletions

View File

@ -1418,6 +1418,13 @@ func TestReadConfigPaths_dir(t *testing.T) {
t.Fatalf("err: %s", err)
}
// An empty file shouldn't be read
err = ioutil.WriteFile(filepath.Join(td, "d.json"),
[]byte{}, 0664)
if err != nil {
t.Fatalf("err: %s", err)
}
config, err := ReadConfigPaths([]string{td})
if err != nil {
t.Fatalf("err: %s", err)