From 9a121853236a8c77693f14d21d27987e5832176a Mon Sep 17 00:00:00 2001 From: Bo Yang Date: Mon, 27 Apr 2015 14:47:04 -0700 Subject: [PATCH] Handle un-handled cases of TestOneof2 in unittest Change-Id: I8f082ee3117ed873ab472a539867ff7cae58e8fd --- src/google/protobuf/compiler/cpp/cpp_unittest.cc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/google/protobuf/compiler/cpp/cpp_unittest.cc b/src/google/protobuf/compiler/cpp/cpp_unittest.cc index cc758cf5ee..9d14a924f0 100644 --- a/src/google/protobuf/compiler/cpp/cpp_unittest.cc +++ b/src/google/protobuf/compiler/cpp/cpp_unittest.cc @@ -1392,6 +1392,12 @@ class OneofTest : public testing::Test { case unittest::TestOneof2::kFooString: EXPECT_TRUE(message.has_foo_string()); break; + case unittest::TestOneof2::kFooCord: + EXPECT_TRUE(message.has_foo_cord()); + break; + case unittest::TestOneof2::kFooStringPiece: + EXPECT_TRUE(message.has_foo_string_piece()); + break; case unittest::TestOneof2::kFooBytes: EXPECT_TRUE(message.has_foo_bytes()); break; @@ -1404,6 +1410,9 @@ class OneofTest : public testing::Test { case unittest::TestOneof2::kFoogroup: EXPECT_TRUE(message.has_foogroup()); break; + case unittest::TestOneof2::kFooLazyMessage: + EXPECT_TRUE(message.has_foo_lazy_message()); + break; case unittest::TestOneof2::FOO_NOT_SET: break; }