From d6dd6f25f4e900d6099098d5d1f0bd52f0581750 Mon Sep 17 00:00:00 2001 From: yang-g Date: Thu, 20 Dec 2018 15:37:30 -0800 Subject: Correctly reference the internal string for socket mutator arg --- test/cpp/common/channel_arguments_test.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test') diff --git a/test/cpp/common/channel_arguments_test.cc b/test/cpp/common/channel_arguments_test.cc index 183d2afa78..12fd9784f4 100644 --- a/test/cpp/common/channel_arguments_test.cc +++ b/test/cpp/common/channel_arguments_test.cc @@ -209,6 +209,9 @@ TEST_F(ChannelArgumentsTest, SetSocketMutator) { channel_args_.SetSocketMutator(mutator0); EXPECT_TRUE(HasArg(arg0)); + // Exercise the copy constructor because we ran some sanity checks in it. + grpc::ChannelArguments new_args{channel_args_}; + channel_args_.SetSocketMutator(mutator1); EXPECT_TRUE(HasArg(arg1)); // arg0 is replaced by arg1 -- cgit v1.2.3