aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/cpp/interop
diff options
context:
space:
mode:
authorGravatar yang-g <yangg@google.com>2015-08-20 12:18:28 -0700
committerGravatar yang-g <yangg@google.com>2015-08-20 12:18:28 -0700
commit961eeb0b44af09b816b9b2aa8e331ac549e6b58b (patch)
tree3ae3ca26c144b9eeeef8bef8623b5692baa607d0 /test/cpp/interop
parentc317f07b5668d6e081a54ad9f6636555f35e0994 (diff)
parent6f98162b0c8e34476a2188186337a7c29bc6bd10 (diff)
Merge remote-tracking branch 'upstream/master' into docs
Diffstat (limited to 'test/cpp/interop')
-rw-r--r--test/cpp/interop/client_helper.cc14
-rw-r--r--test/cpp/interop/client_helper.h14
2 files changed, 11 insertions, 17 deletions
diff --git a/test/cpp/interop/client_helper.cc b/test/cpp/interop/client_helper.cc
index 91c8dbc0c3..be652a4add 100644
--- a/test/cpp/interop/client_helper.cc
+++ b/test/cpp/interop/client_helper.cc
@@ -52,7 +52,6 @@
#include "test/core/security/oauth2_utils.h"
#include "test/cpp/util/create_test_channel.h"
-#include "src/core/surface/call.h"
#include "src/cpp/client/secure_credentials.h"
DECLARE_bool(enable_ssl);
@@ -141,18 +140,5 @@ std::shared_ptr<Channel> CreateChannelForTestCase(
}
}
-InteropClientContextInspector::InteropClientContextInspector(
- const ::grpc::ClientContext& context)
- : context_(context) {}
-
-grpc_compression_algorithm
-InteropClientContextInspector::GetCallCompressionAlgorithm() const {
- return grpc_call_get_compression_algorithm(context_.call_);
-}
-
-gpr_uint32 InteropClientContextInspector::GetMessageFlags() const {
- return grpc_call_get_message_flags(context_.call_);
-}
-
} // namespace testing
} // namespace grpc
diff --git a/test/cpp/interop/client_helper.h b/test/cpp/interop/client_helper.h
index 3b46d87016..d4c14433a9 100644
--- a/test/cpp/interop/client_helper.h
+++ b/test/cpp/interop/client_helper.h
@@ -39,6 +39,8 @@
#include <grpc++/config.h>
#include <grpc++/channel.h>
+#include "src/core/surface/call.h"
+
namespace grpc {
namespace testing {
@@ -51,11 +53,17 @@ std::shared_ptr<Channel> CreateChannelForTestCase(
class InteropClientContextInspector {
public:
- InteropClientContextInspector(const ::grpc::ClientContext& context);
+ InteropClientContextInspector(const ::grpc::ClientContext& context)
+ : context_(context) {}
// Inspector methods, able to peek inside ClientContext, follow.
- grpc_compression_algorithm GetCallCompressionAlgorithm() const;
- gpr_uint32 GetMessageFlags() const;
+ grpc_compression_algorithm GetCallCompressionAlgorithm() const {
+ return grpc_call_get_compression_algorithm(context_.call_);
+ }
+
+ gpr_uint32 GetMessageFlags() const {
+ return grpc_call_get_message_flags(context_.call_);
+ }
private:
const ::grpc::ClientContext& context_;