aboutsummaryrefslogtreecommitdiffstats
path: root/fnet/src/tests/frt/rpc/detach_return_invoke.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'fnet/src/tests/frt/rpc/detach_return_invoke.cpp')
-rw-r--r--fnet/src/tests/frt/rpc/detach_return_invoke.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/fnet/src/tests/frt/rpc/detach_return_invoke.cpp b/fnet/src/tests/frt/rpc/detach_return_invoke.cpp
index ab21c62bb68..43a61cd9bcd 100644
--- a/fnet/src/tests/frt/rpc/detach_return_invoke.cpp
+++ b/fnet/src/tests/frt/rpc/detach_return_invoke.cpp
@@ -39,13 +39,13 @@ struct Server : public FRT_Invokable
TEST("detach return invoke") {
Receptor receptor;
- FRT_Supervisor orb;
- Server server(orb, receptor);
- ASSERT_TRUE(orb.Listen(0));
- ASSERT_TRUE(orb.Start());
- std::string spec = vespalib::make_string("tcp/localhost:%d", orb.GetListenPort());
- FRT_Target *target = orb.Get2WayTarget(spec.c_str());
- FRT_RPCRequest *req = orb.AllocRPCRequest();
+ fnet::frt::StandaloneFRT frtServer;
+ FRT_Supervisor & supervisor = frtServer.supervisor();
+ Server server(supervisor, receptor);
+ ASSERT_TRUE(supervisor.Listen(0));
+ std::string spec = vespalib::make_string("tcp/localhost:%d", supervisor.GetListenPort());
+ FRT_Target *target = supervisor.Get2WayTarget(spec.c_str());
+ FRT_RPCRequest *req = supervisor.AllocRPCRequest();
req->SetMethodName("hook");
target->InvokeSync(req, 5.0);
@@ -58,7 +58,6 @@ TEST("detach return invoke") {
}
req->SubRef();
target->SubRef();
- orb.ShutDown(true);
if (receptor.req != 0) {
EXPECT_TRUE(!receptor.req->IsError());
receptor.req->SubRef();