|
|
|
@ -73,7 +73,8 @@ class CrashTest : public ::testing::Test { |
|
|
|
|
protected: |
|
|
|
|
CrashTest() {} |
|
|
|
|
|
|
|
|
|
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> CreateServerAndStub() { |
|
|
|
|
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> |
|
|
|
|
CreateServerAndStub() { |
|
|
|
|
auto port = grpc_pick_unused_port_or_die(); |
|
|
|
|
auto addr = (std::ostringstream() << "localhost:" << port).str(); |
|
|
|
|
server_.reset(new SubProcess({ |
|
|
|
@ -81,7 +82,8 @@ class CrashTest : public ::testing::Test { |
|
|
|
|
(std::ostringstream() << "--address=" << addr).str(), |
|
|
|
|
})); |
|
|
|
|
GPR_ASSERT(server_); |
|
|
|
|
return grpc::cpp::test::util::TestService::NewStub(CreateChannel(addr, InsecureCredentials(), ChannelArguments())); |
|
|
|
|
return grpc::cpp::test::util::TestService::NewStub( |
|
|
|
|
CreateChannel(addr, InsecureCredentials(), ChannelArguments())); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void KillServer() { |
|
|
|
|