mirror of
https://github.com/yannh/kubeconform.git
synced 2026-02-21 19:07:00 +00:00
feat(validator): add c.AssertFormat() to fix tests
This commit is contained in:
parent
5f834b4f27
commit
49066ce365
1 changed files with 1 additions and 0 deletions
|
|
@ -377,6 +377,7 @@ func downloadSchema(registries []registry.Registry, l jsonschema.SchemeURLLoader
|
||||||
c.RegisterFormat(&jsonschema.Format{"duration", validateDuration})
|
c.RegisterFormat(&jsonschema.Format{"duration", validateDuration})
|
||||||
c.UseLoader(l)
|
c.UseLoader(l)
|
||||||
c.DefaultDraft(jsonschema.Draft2020)
|
c.DefaultDraft(jsonschema.Draft2020)
|
||||||
|
c.AssertFormat()
|
||||||
if err := c.AddResource(path, s); err != nil {
|
if err := c.AddResource(path, s); err != nil {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue