Home
last modified time | relevance | path

Searched refs:message2 (Results 1 – 25 of 74) sorted by relevance

123

/third_party/protobuf/src/google/protobuf/
Dlite_unittest.cc93 protobuf_unittest::TestAllTypesLite message, message2, message3; in TEST() local
96 message2.CopyFrom(message); in TEST()
100 TestUtilLite::ExpectAllFieldsSet(message2); in TEST()
112 protobuf_unittest::TestAllExtensionsLite message, message2, message3; in TEST() local
115 message2.CopyFrom(message); in TEST()
119 TestUtilLite::ExpectAllExtensionsSet(message2); in TEST()
132 protobuf_unittest::TestPackedTypesLite message, message2, message3; in TEST() local
135 message2.CopyFrom(message); in TEST()
139 TestUtilLite::ExpectPackedFieldsSet(message2); in TEST()
148 protobuf_unittest::TestPackedExtensionsLite message, message2, message3; in TEST() local
[all …]
Dreflection_ops_unittest.cc60 unittest::TestAllTypes message, message2; in TEST() local
64 ReflectionOps::Copy(message, &message2); in TEST()
66 TestUtil::ExpectAllFieldsSet(message2); in TEST()
69 ReflectionOps::Copy(message2, &message2); in TEST()
70 TestUtil::ExpectAllFieldsSet(message2); in TEST()
74 unittest::TestAllExtensions message, message2; in TEST() local
78 ReflectionOps::Copy(message, &message2); in TEST()
80 TestUtil::ExpectAllExtensionsSet(message2); in TEST()
84 unittest::TestOneof2 message, message2; in TEST() local
86 ReflectionOps::Copy(message, &message2); in TEST()
[all …]
Dgenerated_message_reflection_unittest.cc157 unittest::TestAllTypes message2; in TEST() local
162 reflection->Swap(&message1, &message2); in TEST()
165 TestUtil::ExpectAllFieldsSet(message2); in TEST()
170 unittest::TestAllTypes message2; in TEST() local
173 TestUtil::SetAllFields(&message2); in TEST()
174 TestUtil::ModifyRepeatedFields(&message2); in TEST()
177 reflection->Swap(&message1, &message2); in TEST()
180 TestUtil::ExpectAllFieldsSet(message2); in TEST()
184 reflection->Swap(&message1, &message2); in TEST()
186 EXPECT_EQ(532819, message2.optional_int32()); in TEST()
[all …]
Dextension_set_unittest.cc273 unittest::TestAllExtensions message1, message2; in TEST() local
276 message2.CopyFrom(message1); in TEST()
277 TestUtil::ExpectAllExtensionsSet(message2); in TEST()
278 message2.CopyFrom(message1); // exercise copy when fields already exist in TEST()
279 TestUtil::ExpectAllExtensionsSet(message2); in TEST()
283 unittest::TestPackedExtensions message1, message2; in TEST() local
286 message2.CopyFrom(message1); in TEST()
287 TestUtil::ExpectPackedExtensionsSet(message2); in TEST()
288 message2.CopyFrom(message1); // exercise copy when fields already exist in TEST()
289 TestUtil::ExpectPackedExtensionsSet(message2); in TEST()
[all …]
Dmap_test.cc1992 unittest::TestMap message1, message2; in TEST() local
1995 message2.CopyFrom(message1); in TEST()
1996 MapTestUtil::ExpectMapFieldsSet(message2); in TEST()
1999 message2.CopyFrom(message2); in TEST()
2000 MapTestUtil::ExpectMapFieldsSet(message2); in TEST()
2004 unittest::TestMessageMap message1, message2; in TEST() local
2007 (*message2.mutable_map_int32_message())[0].add_repeated_int32(101); in TEST()
2009 message1.CopyFrom(message2); in TEST()
2017 unittest::TestMap message1, message2; in TEST() local
2021 MapTestUtil::ExpectClear(message2); in TEST()
[all …]
Dgenerated_message_reflection.cc360 void Reflection::SwapField(Message* message1, Message* message2, in SwapField() argument
369 ->Swap(MutableRaw<RepeatedField<TYPE> >(message2, field)); \ in SwapField()
388 MutableRaw<RepeatedPtrFieldBase>(message2, field)); in SwapField()
395 ->Swap(MutableRaw<MapFieldBase>(message2, field)); in SwapField()
399 MutableRaw<RepeatedPtrFieldBase>(message2, field)); in SwapField()
411 *MutableRaw<TYPE>(message2, field)); \ in SwapField()
424 if (GetArena(message1) == GetArena(message2)) { in SwapField()
426 *MutableRaw<Message*>(message2, field)); in SwapField()
429 Message** sub_msg2 = MutableRaw<Message*>(message2, field); in SwapField()
438 ClearField(message2, field); in SwapField()
[all …]
Dpreserve_unknown_enum_test.cc138 proto2_preserve_unknown_enum_unittest::MyMessage message2 = message; in TEST() local
139 message2.DiscardUnknownFields(); in TEST()
140 EXPECT_EQ(0, message2.ByteSizeLong()); in TEST()
165 proto2_preserve_unknown_enum_unittest::MyMessage message2; in TEST() local
166 message2.CopyFrom(*message); in TEST()
167 message2.DiscardUnknownFields(); in TEST()
168 EXPECT_EQ(0, message2.ByteSizeLong()); in TEST()
/third_party/protobuf/src/google/protobuf/util/
Dmessage_differencer.cc74 const google::protobuf::Message& message1, const google::protobuf::Message& message2, in ReportAdded() argument
82 const google::protobuf::Message& message1, const google::protobuf::Message& message2, in ReportDeleted() argument
90 const google::protobuf::Message& message1, const google::protobuf::Message& message2, in ReportModified() argument
125 bool IsMatch(const Message& message1, const Message& message2, in IsMatch() argument
128 if (!IsMatchInternal(message1, message2, parent_fields, in IsMatch()
138 const Message& message1, const Message& message2, in IsMatchInternal() argument
147 message1, message2, field, &current_parent_fields)) { in IsMatchInternal()
152 message1, message2, field, -1, -1, &current_parent_fields)) { in IsMatchInternal()
159 const Reflection* reflection2 = message2.GetReflection(); in IsMatchInternal()
161 bool has_field2 = reflection2->HasField(message2, field); in IsMatchInternal()
[all …]
Dmessage_differencer.h131 static bool Equals(const Message& message1, const Message& message2);
144 static bool Equivalent(const Message& message1, const Message& message2);
157 const Message& message2);
172 const Message& message2);
247 virtual void ReportAdded(const Message& message1, const Message& message2,
252 const Message& message1, const Message& message2,
257 const Message& message1, const Message& message2,
596 bool Compare(const Message& message1, const Message& message2);
601 const Message& message1, const Message& message2,
643 void ReportAdded(const Message& message1, const Message& message2,
[all …]
Ddelimited_message_util_test.cc55 protobuf_unittest::TestPackedTypes message2; in TEST() local
56 TestUtil::SetPackedFields(&message2); in TEST()
57 EXPECT_TRUE(SerializeDelimitedToOstream(message2, &stream)); in TEST()
71 protobuf_unittest::TestPackedTypes message2; in TEST() local
73 EXPECT_TRUE(ParseDelimitedFromZeroCopyStream(&message2, in TEST()
76 TestUtil::ExpectPackedFieldsSet(message2); in TEST()
79 EXPECT_FALSE(ParseDelimitedFromZeroCopyStream(&message2, in TEST()
/third_party/protobuf/src/google/protobuf/compiler/cpp/
Dcpp_unittest.inc406 UNITTEST::TestAllTypes message1, message2;
409 message2.CopyFrom(message1);
410 TestUtil::ExpectAllFieldsSet(message2);
413 message2.CopyFrom(message2);
414 TestUtil::ExpectAllFieldsSet(message2);
419 UNITTEST::TestAllTypes message1, message2;
423 TestUtil::ExpectClear(message2);
424 message1.Swap(&message2);
425 TestUtil::ExpectAllFieldsSet(message2);
438 UNITTEST::TestAllTypes message1, message2;
[all …]
Dcpp_move_unittest.cc56 protobuf_unittest::TestAllTypes message2(std::move(message1)); in TEST() local
57 TestUtil::ExpectAllFieldsSet(message2); in TEST()
61 EXPECT_EQ(nested, &message2.optional_nested_message()); in TEST()
70 protobuf_unittest::TestAllTypes message2; in TEST() local
71 message2 = std::move(message1); in TEST()
72 TestUtil::ExpectAllFieldsSet(message2); in TEST()
76 EXPECT_EQ(nested, &message2.optional_nested_message()); in TEST()
130 protobuf_unittest::TestAllTypes message2; in TEST() local
133 message2 = std::move(*message1_on_arena); in TEST()
134 EXPECT_NE(nested, &message2.optional_nested_message()); in TEST()
[all …]
/third_party/protobuf/java/core/src/test/java/com/google/protobuf/
DWireFormatLiteTest.java72 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testSerializeExtensionsLite() local
74 TestUtil.assertAllFieldsSet(message2); in testSerializeExtensionsLite()
83 TestPackedTypes message2 = TestUtil.getPackedSet(); in testSerializePackedExtensionsLite() local
84 ByteString rawBytes2 = message2.toByteString(); in testSerializePackedExtensionsLite()
99 TestAllExtensionsLite message2 = TestAllExtensionsLite.parseFrom(rawBytes, registryLite); in testParseExtensionsLite() local
100 TestUtil.assertAllExtensionsSet(message2); in testParseExtensionsLite()
101 message2 = TestAllExtensionsLite.parseFrom(message.toByteArray(), registryLite); in testParseExtensionsLite()
102 TestUtil.assertAllExtensionsSet(message2); in testParseExtensionsLite()
112 TestPackedExtensionsLite message2 = TestPackedExtensionsLite.parseFrom(rawBytes, registry); in testParsePackedExtensionsLite() local
113 TestUtil.assertPackedExtensionsSet(message2); in testParsePackedExtensionsLite()
[all …]
DWireFormatTest.java70 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testSerialization() local
72 TestUtil.assertAllFieldsSet(message2); in testSerialization()
81 TestPackedTypes message2 = TestPackedTypes.parseFrom(rawBytes); in testSerializationPacked() local
83 TestUtil.assertPackedFieldsSet(message2); in testSerializationPacked()
95 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testSerializeExtensions() local
97 TestUtil.assertAllFieldsSet(message2); in testSerializeExtensions()
106 TestPackedTypes message2 = TestUtil.getPackedSet(); in testSerializePackedExtensions() local
107 ByteString rawBytes2 = message2.toByteString(); in testSerializePackedExtensions()
127 TestPackedTypes message2 = TestPackedTypes.parseFrom(outputStream.toByteArray()); in testSerializationPackedWithoutGetSerializedSize() local
129 TestUtil.assertPackedFieldsSet(message2); in testSerializationPackedWithoutGetSerializedSize()
[all …]
DDynamicMessageTest.java163 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testDynamicMessageSerialization() local
165 TestUtil.assertAllFieldsSet(message2); in testDynamicMessageSerialization()
178 Message message2 = DynamicMessage.parseFrom(TestAllTypes.getDescriptor(), rawBytes); in testDynamicMessageParsing() local
179 reflectionTester.assertAllFieldsSetViaReflection(message2); in testDynamicMessageParsing()
182 Message message3 = message2.getParserForType().parseFrom(rawBytes); in testDynamicMessageParsing()
194 Message message2 = in testDynamicMessageExtensionParsing() local
196 extensionsReflectionTester.assertAllFieldsSetViaReflection(message2); in testDynamicMessageExtensionParsing()
205 TestPackedTypes message2 = TestPackedTypes.parseFrom(rawBytes); in testDynamicMessagePackedSerialization() local
207 TestUtil.assertPackedFieldsSet(message2); in testDynamicMessagePackedSerialization()
220 Message message2 = DynamicMessage.parseFrom(TestPackedTypes.getDescriptor(), rawBytes); in testDynamicMessagePackedParsing() local
[all …]
DGeneratedMessageTest.java1375 OuterClassNameTest2OuterClass.TestMessage2.NestedMessage.OuterClassNameTest2 message2 = in testConflictingOuterClassName() local
1378 assertEquals(0, message2.getSerializedSize()); in testConflictingOuterClassName()
1447 TestOneof2 message2 = builder.build(); in testOneofTypes() local
1448 assertFalse(message2.hasFooInt()); in testOneofTypes()
1449 assertEquals(0, message2.getFooInt()); in testOneofTypes()
1463 TestOneof2 message2 = builder.build(); in testOneofTypes() local
1464 assertFalse(message2.hasFooEnum()); in testOneofTypes()
1465 assertEquals(TestOneof2.NestedEnum.FOO, message2.getFooEnum()); in testOneofTypes()
1481 TestOneof2 message2 = builder.buildPartial(); in testOneofTypes() local
1482 assertFalse(message2.hasFooString()); in testOneofTypes()
[all …]
DLazyFieldLiteTest.java144 TestAllTypes message2 = TestAllTypes.newBuilder().setOptionalInt64(2).build(); in testMergeBeforeParsing() local
145 LazyFieldLite field2 = createLazyFieldLiteFromMessage(message2); in testMergeBeforeParsing()
156 TestAllTypes message2 = TestAllTypes.newBuilder().setOptionalInt64(2).build(); in testMergeOneNotParsed() local
162 LazyFieldLite field2 = createLazyFieldLiteFromMessage(message2); in testMergeOneNotParsed()
168 field2 = createLazyFieldLiteFromMessage(message2); in testMergeOneNotParsed()
/third_party/protobuf/java/compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/
DWireFormatTest.java63 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testSerialization() local
65 TestUtil.assertAllFieldsSet(message2); in testSerialization()
74 TestPackedTypes message2 = TestPackedTypes.parseFrom(rawBytes); in testSerializationPacked() local
76 TestUtil.assertPackedFieldsSet(message2); in testSerializationPacked()
88 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testSerializeExtensions() local
90 TestUtil.assertAllFieldsSet(message2); in testSerializeExtensions()
99 TestPackedTypes message2 = TestUtil.getPackedSet(); in testSerializePackedExtensions() local
100 ByteString rawBytes2 = message2.toByteString(); in testSerializePackedExtensions()
121 TestPackedTypes message2 = TestPackedTypes.parseFrom( in testSerializationPackedWithoutGetSerializedSize() local
124 TestUtil.assertPackedFieldsSet(message2); in testSerializationPackedWithoutGetSerializedSize()
[all …]
DDynamicMessageTest.java170 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testDynamicMessageSerialization() local
172 TestUtil.assertAllFieldsSet(message2); in testDynamicMessageSerialization()
185 Message message2 = in testDynamicMessageParsing() local
187 reflectionTester.assertAllFieldsSetViaReflection(message2); in testDynamicMessageParsing()
190 Message message3 = message2.getParserForType().parseFrom(rawBytes); in testDynamicMessageParsing()
202 Message message2 = message.getParserForType().parseFrom( in testDynamicMessageExtensionParsing() local
204 extensionsReflectionTester.assertAllFieldsSetViaReflection(message2); in testDynamicMessageExtensionParsing()
214 TestPackedTypes message2 = TestPackedTypes.parseFrom(rawBytes); in testDynamicMessagePackedSerialization() local
216 TestUtil.assertPackedFieldsSet(message2); in testDynamicMessagePackedSerialization()
229 Message message2 = in testDynamicMessagePackedParsing() local
[all …]
DCodedInputStreamTest.java263 TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes); in testReadWholeMessage() local
264 TestUtil.assertAllFieldsSet(message2); in testReadWholeMessage()
268 message2 = TestAllTypes.parseFrom( in testReadWholeMessage()
270 TestUtil.assertAllFieldsSet(message2); in testReadWholeMessage()
347 TestAllTypes message2 = in testReadHugeBlob() local
350 assertEquals(message.getOptionalBytes(), message2.getOptionalBytes()); in testReadHugeBlob()
353 TestAllTypes message3 = TestAllTypes.newBuilder(message2) in testReadHugeBlob()
/third_party/protobuf/objectivec/Tests/
DGPBMessageTests.m454 GPBMessage *message2 = [TestAllExtensions message];
455 [message2 setExtension:[UnittestRoot optionalInt32Extension] value:@1];
457 [message2 addExtension:[UnittestRoot repeatedInt32Extension] value:@2];
459 description = [message2 description];
591 TestAllTypes *message2 = [TestAllTypes message];
592 XCTAssertEqualObjects(message, message2);
612 GPBMessage *message2 = [TestAllExtensions message];
613 [message2 addExtension:[UnittestRoot repeatedInt32Extension] value:@1];
616 [[message2 getExtension:[UnittestRoot repeatedInt32Extension]] count],
618 [message2 clearExtension:[UnittestRoot repeatedInt32Extension]];
[all …]
DGPBWireFormatTests.m52 TestAllTypes* message2 = [TestAllTypes parseFromData:rawBytes error:NULL];
54 [self assertAllFieldsSet:message2 repeatedCount:kGPBDefaultRepeatCount];
65 TestPackedTypes* message2 =
68 [self assertPackedFieldsSet:message2 repeatedCount:kGPBDefaultRepeatCount];
82 TestAllTypes* message2 = [TestAllTypes parseFromData:rawBytes error:NULL];
84 [self assertAllFieldsSet:message2 repeatedCount:kGPBDefaultRepeatCount];
95 TestPackedTypes* message2 =
97 NSData* rawBytes2 = message2.data;
113 TestAllExtensions* message2 = [TestAllExtensions parseFromData:rawBytes
117 [self assertAllExtensionsSet:message2 repeatedCount:kGPBDefaultRepeatCount];
[all …]
/third_party/protobuf/js/
Dmessage_test.js926 var message2 =
929 message2.setExtension(
931 message2.setExtension(
935 message2.setExtension(proto.jspb.exttest.reverse.c, 23333);
939 message2.getExtension(
943 message2.getExtension(
946 assertEquals(23333, message2.getExtension(proto.jspb.exttest.reverse.c));
953 var message2 = new proto.jspb.circulartest.MessageField2;
958 message2.setB(nestMessage1);
962 assertEquals(1, message2.getB().getA());
[all …]
/third_party/node/test/parallel/
Dtest-worker-message-port-receive-message.js9 const message2 = { foo: 'bar' }; variable
15 port1.postMessage(message2);
17 assert.deepStrictEqual(receiveMessageOnPort(port2), { message: message2 });
/third_party/protobuf/csharp/compatibility_tests/v3.0.0/src/Google.Protobuf.Test/
DGeneratedMessageTest.cs54 var message2 = new TestAllTypes(); // SingleForeignMessage is null in EmptyMessageFieldDistinctFromMissingMessageField()
55 EqualityTester.AssertInequality(message1, message2); in EmptyMessageFieldDistinctFromMissingMessageField()
606 var message2 = new TestAllTypes { OneofUint32 = 0 }; in Oneof_DefaultValuesNotEqual()
608 Assert.AreEqual(TestAllTypes.OneofFieldOneofCase.OneofUint32, message2.OneofFieldCase); in Oneof_DefaultValuesNotEqual()
609 Assert.AreNotEqual(message1, message2); in Oneof_DefaultValuesNotEqual()
621 var message2 = TestAllTypes.Parser.ParseFrom(bytes); in OneofSerialization_NonDefaultValue()
622 Assert.AreEqual(message, message2); in OneofSerialization_NonDefaultValue()
623 Assert.AreEqual(TestAllTypes.OneofFieldOneofCase.OneofUint32, message2.OneofFieldCase); in OneofSerialization_NonDefaultValue()
635 var message2 = TestAllTypes.Parser.ParseFrom(bytes); in OneofSerialization_DefaultValue()
636 Assert.AreEqual(message, message2); in OneofSerialization_DefaultValue()
[all …]

123