(t *testing.T)
| 40 | } |
| 41 | |
| 42 | func TestValidateUndefinedTopLevelOption(t *testing.T) { |
| 43 | config := map[string]any{ |
| 44 | "helicopters": map[string]any{ |
| 45 | "foo": map[string]any{ |
| 46 | "image": "busybox", |
| 47 | }, |
| 48 | }, |
| 49 | } |
| 50 | |
| 51 | err := Validate(config) |
| 52 | assert.ErrorContains(t, err, "additional properties 'helicopters' not allowed") |
| 53 | } |
| 54 | |
| 55 | func TestValidateAllowsXTopLevelFields(t *testing.T) { |
| 56 | config := map[string]any{ |
nothing calls this directly
no test coverage detected
searching dependent graphs…