(t *testing.T)
| 498 | } |
| 499 | |
| 500 | func TestUnmarshalExact(t *testing.T) { |
| 501 | v := New() |
| 502 | target := &testUnmarshalExtra{} |
| 503 | v.SetConfigType("yaml") |
| 504 | r := bytes.NewReader(yamlExampleWithExtras) |
| 505 | v.ReadConfig(r) |
| 506 | err := v.UnmarshalExact(target) |
| 507 | assert.Error(t, err, "UnmarshalExact should error when populating a struct from a conf that contains unused fields") |
| 508 | } |
| 509 | |
| 510 | func TestOverrides(t *testing.T) { |
| 511 | v := New() |
nothing calls this directly
no test coverage detected