From 156161dfcde38b72c55ead02cacff7087c93a4d8 Mon Sep 17 00:00:00 2001 From: Thomas Van Lenten Date: Wed, 3 Jan 2018 11:19:53 -0500 Subject: Properly copy maps with string keys but pod values. Add tests to cover all the common special casing in the runtime code to ensure things come out correctly. --- objectivec/Tests/unittest_objc.proto | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'objectivec/Tests/unittest_objc.proto') diff --git a/objectivec/Tests/unittest_objc.proto b/objectivec/Tests/unittest_objc.proto index e5577faf..b0eb4723 100644 --- a/objectivec/Tests/unittest_objc.proto +++ b/objectivec/Tests/unittest_objc.proto @@ -58,6 +58,27 @@ message TestRecursiveMessageWithRepeatedField { map str_to_str = 5; } +// Message with a few types of maps to cover the different custom flows +// in the runtime. +message TestMessageOfMaps { + map str_to_str = 1; + + map str_to_int = 2; + map int_to_str = 3; + map int_to_int = 4; + + map str_to_bool = 5; + map bool_to_str = 6; + map bool_to_bool = 7; + + map int_to_bool = 8; + map bool_to_int = 9; + + map str_to_msg = 10; + map int_to_msg = 11; + map bool_to_msg = 12; +} + // Recursive message and extension to for testing autocreators at different // depths. message TestRecursiveExtension { -- cgit v1.2.3