@@ -239,7 +239,7 @@ func TestUnionRatcheting(t *testing.T) {
239239 newStruct : & testStruct {},
240240 expected : field.ErrorList {
241241 field .Invalid (nil , "" , "must specify one of: `m1`, `m2`, `m3`, `m4`" ),
242- }. WithOrigin ( "union" ) ,
242+ },
243243 },
244244 {
245245 name : "both empty struct" ,
@@ -268,7 +268,7 @@ func TestUnionRatcheting(t *testing.T) {
268268 },
269269 expected : field.ErrorList {
270270 field .Invalid (nil , "{m1, m2}" , "must specify exactly one of: `m1`, `m2`, `m3`, `m4`" ),
271- }. WithOrigin ( "union" ) ,
271+ },
272272 },
273273 {
274274 name : "slice member ratcheting: unchanged membership" ,
@@ -286,15 +286,15 @@ func TestUnionRatcheting(t *testing.T) {
286286 newStruct : & testStruct {M3 : []string {}},
287287 expected : field.ErrorList {
288288 field .Invalid (nil , "" , "must specify one of: `m1`, `m2`, `m3`, `m4`" ),
289- }. WithOrigin ( "union" ) ,
289+ },
290290 },
291291 {
292292 name : "empty map is not set" ,
293293 oldStruct : nil ,
294294 newStruct : & testStruct {M4 : map [string ]string {}},
295295 expected : field.ErrorList {
296296 field .Invalid (nil , "" , "must specify one of: `m1`, `m2`, `m3`, `m4`" ),
297- }. WithOrigin ( "union" ) ,
297+ },
298298 },
299299 }
300300
@@ -454,7 +454,7 @@ func TestDiscriminatedUnionRatcheting(t *testing.T) {
454454 },
455455 expected : field.ErrorList {
456456 field .Invalid (field .NewPath ("m3" ), "" , "must be specified when `d` is \" m3\" " ),
457- }. WithOrigin ( "union" ) ,
457+ },
458458 },
459459 {
460460 name : "empty map is not set" ,
@@ -468,7 +468,7 @@ func TestDiscriminatedUnionRatcheting(t *testing.T) {
468468 },
469469 expected : field.ErrorList {
470470 field .Invalid (field .NewPath ("m4" ), "" , "must be specified when `d` is \" m4\" " ),
471- }. WithOrigin ( "union" ) ,
471+ },
472472 },
473473 }
474474
0 commit comments