@@ -45,10 +45,7 @@ func TestConfig_UnmarshalYAML(t *testing.T) {
4545 Projects : nil ,
4646 Workflows : nil ,
4747 },
48- expErr : `[1:1] unknown field "invalid"
49- > 1 | invalid: key
50- ^
51- ` ,
48+ expErr : "yaml: unmarshal errors:\n line 1: field invalid not found in type raw.RepoCfg" ,
5249 },
5350 {
5451 description : "version set to 2" ,
@@ -94,11 +91,7 @@ func TestConfig_UnmarshalYAML(t *testing.T) {
9491 Projects : nil ,
9592 Workflows : nil ,
9693 },
97- expErr : `[2:6] mapping was used where sequence is expected
98- 1 | projects:
99- > 2 | key: value
100- ^
101- ` ,
94+ expErr : "yaml: unmarshal errors:\n line 2: cannot unmarshal !!map into []raw.Project" ,
10295 },
10396 {
10497 description : "projects with a scalar" ,
@@ -108,10 +101,7 @@ func TestConfig_UnmarshalYAML(t *testing.T) {
108101 Projects : nil ,
109102 Workflows : nil ,
110103 },
111- expErr : `[1:11] string was used where sequence is expected
112- > 1 | projects: value
113- ^
114- ` ,
104+ expErr : "yaml: unmarshal errors:\n line 1: cannot unmarshal !!str `value` into []raw.Project" ,
115105 },
116106 {
117107 description : "automerge not a boolean" ,
@@ -121,11 +111,7 @@ func TestConfig_UnmarshalYAML(t *testing.T) {
121111 Projects : nil ,
122112 Workflows : nil ,
123113 },
124- expErr : `[2:12] cannot unmarshal string into Go struct field RepoCfg.Automerge of type bool
125- 1 | version: 3
126- > 2 | automerge: notabool
127- ^
128- ` ,
114+ expErr : "yaml: unmarshal errors:\n line 2: cannot unmarshal !!str `notabool` into bool" ,
129115 },
130116 {
131117 description : "parallel apply not a boolean" ,
@@ -135,11 +121,8 @@ func TestConfig_UnmarshalYAML(t *testing.T) {
135121 Projects : nil ,
136122 Workflows : nil ,
137123 },
138- expErr : `[2:17] cannot unmarshal string into Go struct field RepoCfg.ParallelApply of type bool
139- 1 | version: 3
140- > 2 | parallel_apply: notabool
141- ^
142- ` },
124+ expErr : "yaml: unmarshal errors:\n line 2: cannot unmarshal !!str `notabool` into bool" ,
125+ },
143126 {
144127 description : "should use values if set" ,
145128 input : `
0 commit comments