(t *testing.T)
| 267 | } |
| 268 | |
| 269 | func TestUnmarshalAnyMixAndMatch(t *testing.T) { |
| 270 | pb := &anypb.Any{} |
| 271 | err := proto.UnmarshalText(` |
| 272 | value: "\n\x05Monty" |
| 273 | [type.googleapis.com/a/path/proto3_test.Nested]: < |
| 274 | bunny: "Rabbit of Caerbannog" |
| 275 | > |
| 276 | `, pb) |
| 277 | want := `line 5: Any message unpacked multiple times, or "value" already set` |
| 278 | if err.Error() != want { |
| 279 | t.Errorf("incorrect error:\ngot: %v\nwant: %v", err.Error(), want) |
| 280 | } |
| 281 | } |
| 282 | |
| 283 | // textMessage implements the methods that allow it to marshal and unmarshal |
| 284 | // itself as text. |
nothing calls this directly
no test coverage detected