aboutsummaryrefslogtreecommitdiff
path: root/csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs
diff options
context:
space:
mode:
authorJon Skeet <jonskeet@google.com>2015-07-16 21:34:10 +0100
committerJon Skeet <jonskeet@google.com>2015-07-16 21:34:10 +0100
commit3da90e9f54f9648a76a0172e5af94f4a0a00a5e8 (patch)
treeecc1467939ab45c986992b44934ad148a71d9c8f /csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs
parent8a0312b20156aa4df092cb6b3c665ef48cb6fa54 (diff)
downloadprotobuf-3da90e9f54f9648a76a0172e5af94f4a0a00a5e8.tar.gz
protobuf-3da90e9f54f9648a76a0172e5af94f4a0a00a5e8.tar.bz2
protobuf-3da90e9f54f9648a76a0172e5af94f4a0a00a5e8.zip
Make the map test actually test the code...
Diffstat (limited to 'csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs')
-rw-r--r--csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs b/csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs
index c85223f3..6c706014 100644
--- a/csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs
+++ b/csharp/src/ProtocolBuffers.Test/WellKnownTypes/WrappersTest.cs
@@ -167,6 +167,13 @@ namespace Google.Protobuf.WellKnownTypes
Uint32Field = { { 15, uint.MaxValue }, { 16, uint.MinValue }, { 17, 0U } },
Uint64Field = { { 18, ulong.MaxValue }, { 19, ulong.MinValue }, { 20, 0UL } },
};
+
+ var bytes = message.ToByteArray();
+ var parsed = MapWellKnownTypes.Parser.ParseFrom(bytes);
+
+ Assert.AreEqual(message, parsed);
+ // Just to test a single value for sanity...
+ Assert.AreEqual("Second", message.StringField[12]);
}
[Test]