|
44 | 44 | marshaler = Marshaler{}
|
45 | 45 |
|
46 | 46 | marshalerAllOptions = Marshaler{
|
47 |
| - EnumsAsString: true, |
48 |
| - Indent: " ", |
| 47 | + Indent: " ", |
49 | 48 | }
|
50 | 49 |
|
51 | 50 | simpleObject = &pb.Simple{
|
@@ -182,8 +181,8 @@ var (
|
182 | 181 | RRepeats: []*pb.Repeats{innerRepeats, innerRepeats2},
|
183 | 182 | }
|
184 | 183 |
|
185 |
| - complexObjectJSON = `{"color":1,` + |
186 |
| - `"r_color":[0,1,2],` + |
| 184 | + complexObjectJSON = `{"color":"GREEN",` + |
| 185 | + `"r_color":["RED","GREEN","BLUE"],` + |
187 | 186 | `"simple":{"o_int32":-32},` +
|
188 | 187 | `"r_simple":[{"o_int32":-32},{"o_int64":"25"}],` +
|
189 | 188 | `"repeats":{"r_string":["roses","red"]},` +
|
@@ -269,7 +268,7 @@ var marshalingTests = []struct {
|
269 | 268 | {"repeated fields pretty object", marshalerAllOptions, repeatsObject, repeatsObjectPrettyJSON},
|
270 | 269 | {"nested message/enum flat object", marshaler, complexObject, complexObjectJSON},
|
271 | 270 | {"nested message/enum pretty object", marshalerAllOptions, complexObject, complexObjectPrettyJSON},
|
272 |
| - {"enum-string flat object", Marshaler{EnumsAsString: true}, |
| 271 | + {"enum-string flat object", Marshaler{}, |
273 | 272 | &pb.Widget{Color: pb.Widget_BLUE.Enum()}, `{"color":"BLUE"}`},
|
274 | 273 | {"enum-value pretty object", Marshaler{EnumsAsInts: true, Indent: " "},
|
275 | 274 | &pb.Widget{Color: pb.Widget_BLUE.Enum()}, colorPrettyJSON},
|
|
0 commit comments