tracks/go/exercises/allergies/.meta/gen.go in trackler-2.2.1.77 vs tracks/go/exercises/allergies/.meta/gen.go in trackler-2.2.1.78

- old
+ new

@@ -29,20 +29,24 @@ type testGroup struct { Description string Cases []json.RawMessage `property:"RAW"` AllergicToCases []struct { Description string - Score uint - Expected []struct { + Input struct { + Score uint + } + Expected []struct { Substance string Result bool } } `property:"allergicTo"` ListCases []struct { Description string - Score uint - Expected []string + Input struct { + Score uint + } + Expected []string } `property:"list"` } var tmpl = `package allergies @@ -62,11 +66,11 @@ expected []allergicResult }{ {{- range .AllergicToCases }} { description: {{.Description | printf "%q"}}, - score: {{.Score}}, + score: {{.Input.Score}}, expected: []allergicResult{ {{range .Expected}} { {{.Substance | printf "%q"}}, {{.Result}} },{{end}} }, }, {{- end }} @@ -78,10 +82,10 @@ description string score uint expected []string }{ {{- range .ListCases }} - { {{.Description | printf "%q"}}, {{.Score}}, {{.Expected | printf "%#v"}}}, + { {{.Description | printf "%q"}}, {{.Input.Score}}, {{.Expected | printf "%#v"}}}, {{- end }} } {{- end }} {{end}} `