diff options
author | Jan Tattermusch <jtattermusch@users.noreply.github.com> | 2016-01-19 19:38:16 -0800 |
---|---|---|
committer | Jan Tattermusch <jtattermusch@users.noreply.github.com> | 2016-01-19 19:38:16 -0800 |
commit | 8c5260b21bb0e217e91375893d507a0ef6578d67 (patch) | |
tree | 1c72120a82fab876f5713a97f2fde16910fef05a /csharp/src/Google.Protobuf.Test/JsonParserTest.cs | |
parent | 6794d17c948f1b36d8e77a91568a40456ec8ada3 (diff) | |
parent | 5dba7d7b4cac6f2f4250ceaca27fb6024f4aeb54 (diff) | |
download | protobuf-8c5260b21bb0e217e91375893d507a0ef6578d67.tar.gz protobuf-8c5260b21bb0e217e91375893d507a0ef6578d67.tar.bz2 protobuf-8c5260b21bb0e217e91375893d507a0ef6578d67.zip |
Merge pull request #1096 from jskeet/custom-to-string
Introduce ICustomDiagnosticMessage to allow for custom string formatting
Diffstat (limited to 'csharp/src/Google.Protobuf.Test/JsonParserTest.cs')
-rw-r--r-- | csharp/src/Google.Protobuf.Test/JsonParserTest.cs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/csharp/src/Google.Protobuf.Test/JsonParserTest.cs b/csharp/src/Google.Protobuf.Test/JsonParserTest.cs index 612a7b12..c4f6dfb4 100644 --- a/csharp/src/Google.Protobuf.Test/JsonParserTest.cs +++ b/csharp/src/Google.Protobuf.Test/JsonParserTest.cs @@ -230,7 +230,7 @@ namespace Google.Protobuf private static void AssertRoundtrip<T>(T message) where T : IMessage<T>, new() { var clone = message.Clone(); - var json = message.ToString(); + var json = JsonFormatter.Default.Format(message); var parsed = JsonParser.Default.Parse<T>(json); Assert.AreEqual(clone, parsed); } |