diff --git a/objectivec/Tests/GPBMessageTests+Runtime.m b/objectivec/Tests/GPBMessageTests+Runtime.m index 1dac79754e..baad082c39 100644 --- a/objectivec/Tests/GPBMessageTests+Runtime.m +++ b/objectivec/Tests/GPBMessageTests+Runtime.m @@ -2446,7 +2446,7 @@ msg.oneofBytes = oneofBytesDefault; break; case Message2_O_OneOfCase_OneofEnum: - msg.oneofEnum = Message3_Enum_Baz; + msg.oneofEnum = Message2_Enum_Baz; break; default: XCTFail(@"shouldn't happen, loop: %zd, value: %d", i, values[i]); diff --git a/objectivec/Tests/GPBMessageTests+Serialization.m b/objectivec/Tests/GPBMessageTests+Serialization.m index 6f20797aee..bb63ec3a26 100644 --- a/objectivec/Tests/GPBMessageTests+Serialization.m +++ b/objectivec/Tests/GPBMessageTests+Serialization.m @@ -559,7 +559,7 @@ //%TEST_ROUNDTRIP_ONEOF_ADV(Message##SYNTAX, String, @"foo", Objects) //%TEST_ROUNDTRIP_ONEOF_ADV(Message##SYNTAX, Bytes, [@"bar" dataUsingEncoding:NSUTF8StringEncoding], Objects) //%GROUP_TEST##SYNTAX()TEST_ROUNDTRIP_ONEOF_ADV(Message##SYNTAX, Message, subMessage, Objects) -//%TEST_ROUNDTRIP_ONEOF(Message##SYNTAX, Enum, Message2_Enum_Bar) +//%TEST_ROUNDTRIP_ONEOF(Message##SYNTAX, Enum, Message##SYNTAX##_Enum_Bar) //%GROUP_CLEANUP##SYNTAX() [subMessage release]; //%} //% @@ -1022,13 +1022,13 @@ { // oneofEnum Message3 *orig = [[Message3 alloc] init]; - orig.oneofEnum = Message2_Enum_Bar; + orig.oneofEnum = Message3_Enum_Bar; XCTAssertEqual(orig.oOneOfCase, Message3_O_OneOfCase_OneofEnum); NSData *data = [orig data]; XCTAssertNotNil(data); Message3 *msg = [Message3 parseFromData:data error:NULL]; XCTAssertEqual(msg.oOneOfCase, Message3_O_OneOfCase_OneofEnum); - XCTAssertEqual(msg.oneofEnum, Message2_Enum_Bar); + XCTAssertEqual(msg.oneofEnum, Message3_Enum_Bar); [orig release]; }