File tree Expand file tree Collapse file tree
pkg/devfile/parser/context Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99func TestSetDevfileAPIVersion (t * testing.T ) {
1010
1111 const (
12- schemaVersion = "2.0.0"
13- validJson = `{"schemaVersion": "2.0.0"}`
12+ schemaVersion = "2.2.0"
13+ validJson = `{"schemaVersion": "2.2.0"}`
14+ concreteSchema = `{"schemaVersion": "2.2.0-latest"}`
1415 emptyJson = "{}"
1516 emptySchemaVersionJson = `{"schemaVersion": ""}`
1617 devfilePath = "/testpath/devfile.yaml"
@@ -30,6 +31,12 @@ func TestSetDevfileAPIVersion(t *testing.T) {
3031 want : schemaVersion ,
3132 wantErr : nil ,
3233 },
34+ {
35+ name : "concrete schemaVersion" ,
36+ devfileCtx : DevfileCtx {rawContent : []byte (concreteSchema ), absPath : devfilePath },
37+ want : schemaVersion ,
38+ wantErr : nil ,
39+ },
3340 {
3441 name : "schemaVersion not present" ,
3542 devfileCtx : DevfileCtx {rawContent : []byte (emptyJson ), absPath : devfilePath },
You can’t perform that action at this time.
0 commit comments