File tree Expand file tree Collapse file tree 6 files changed +9
-332
lines changed Expand file tree Collapse file tree 6 files changed +9
-332
lines changed Original file line number Diff line number Diff line change @@ -8,8 +8,12 @@ require (
88 github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
99 github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
1010 github.com/xeipuuv/gojsonschema v1.2.0 // indirect
11+ golang.org/x/mod v0.19.0 // indirect
12+ golang.org/x/sys v0.19.0 // indirect
1113 gopkg.in/yaml.v2 v2.4.0 // indirect
1214 sigs.k8s.io/yaml v1.3.0 // indirect
15+ tags.cncf.io/container-device-interface/api/producer v0.8.0 // indirect
16+ tags.cncf.io/container-device-interface/specs-go v0.8.0 // indirect
1317)
1418
1519replace (
Original file line number Diff line number Diff line change @@ -17,7 +17,9 @@ github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:
1717github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17UxZ74 =
1818github.com/xeipuuv/gojsonschema v1.2.0 /go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y =
1919golang.org/x/mod v0.19.0 h1:fEdghXQSo20giMthA7cd28ZC+jts4amQ3YMXiP5oMQ8 =
20+ golang.org/x/mod v0.19.0 /go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c =
2021golang.org/x/sys v0.19.0 h1:q5f1RH2jigJ1MoAWp2KTp3gm5zAGFUTarQZ5U386+4o =
22+ golang.org/x/sys v0.19.0 /go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA =
2123gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM =
2224gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 /go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0 =
2325gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY =
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ import (
3131 "sigs.k8s.io/yaml"
3232
3333 schema "github.com/xeipuuv/gojsonschema"
34- "tags.cncf.io/container-device-interface/internal/validation "
34+ "tags.cncf.io/container-device-interface/api/producer "
3535)
3636
3737const (
@@ -305,7 +305,7 @@ func (s *Schema) validateContents(any map[string]interface{}) error {
305305 contents := schemaContents (any )
306306
307307 if specAnnotations , ok := contents .getAnnotations (); ok {
308- if err := validation .ValidateSpecAnnotations ("" , specAnnotations ); err != nil {
308+ if err := producer .ValidateSpecAnnotations ("" , specAnnotations ); err != nil {
309309 return err
310310 }
311311 }
@@ -318,7 +318,7 @@ func (s *Schema) validateContents(any map[string]interface{}) error {
318318 for _ , device := range devices {
319319 name , _ := device .getFieldAsString ("name" )
320320 if annotations , ok := device .getAnnotations (); ok {
321- if err := validation .ValidateSpecAnnotations (name , annotations ); err != nil {
321+ if err := producer .ValidateSpecAnnotations (name , annotations ); err != nil {
322322 return err
323323 }
324324 }
You can’t perform that action at this time.
0 commit comments