diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2022-02-21 18:59:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-21 18:59:31 +0100 |
commit | 9d83cff2851b2126700b1b3cf7b4080ac7c8fb81 (patch) | |
tree | 49b08e0b66fdec37bce82643b5c310db0cb41a7b /config/src/tests/file_acquirer | |
parent | a7e8bb9dcf3c674a3756e0f0383384593856415a (diff) |
Revert "Use a common FNET_Transport owned by Proton in both SceduledExecutor …"
Diffstat (limited to 'config/src/tests/file_acquirer')
-rw-r--r-- | config/src/tests/file_acquirer/file_acquirer_test.cpp | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/config/src/tests/file_acquirer/file_acquirer_test.cpp b/config/src/tests/file_acquirer/file_acquirer_test.cpp index 7daafc37fcf..f289e42edcb 100644 --- a/config/src/tests/file_acquirer/file_acquirer_test.cpp +++ b/config/src/tests/file_acquirer/file_acquirer_test.cpp @@ -3,16 +3,12 @@ #include <vespa/config/file_acquirer/file_acquirer.h> #include <vespa/fnet/frt/supervisor.h> #include <vespa/fnet/frt/rpcrequest.h> -#include <vespa/fnet/transport.h> -#include <vespa/fastos/thread.h> #include <vespa/vespalib/util/stringfmt.h> using namespace config; struct ServerFixture : FRT_Invokable { fnet::frt::StandaloneFRT server; - FastOS_ThreadPool threadPool; - FNET_Transport transport; FRT_Supervisor &orb; vespalib::string spec; @@ -24,16 +20,10 @@ struct ServerFixture : FRT_Invokable { rb.ReturnDesc("file_path", "actual path to the requested file"); } - ServerFixture() - : server(), - threadPool(64_Ki), - transport(), - orb(server.supervisor()) - { + ServerFixture() : server(), orb(server.supervisor()) { init_rpc(); orb.Listen(0); spec = vespalib::make_string("tcp/localhost:%d", orb.GetListenPort()); - transport.Start(&threadPool); } void RPC_waitFor(FRT_RPCRequest *req) { @@ -46,12 +36,10 @@ struct ServerFixture : FRT_Invokable { } } - ~ServerFixture() { - transport.ShutDown(true); - } + ~ServerFixture() = default; }; -TEST_FF("require that files can be acquired over rpc", ServerFixture(), RpcFileAcquirer(f1.transport, f1.spec)) { +TEST_FF("require that files can be acquired over rpc", ServerFixture(), RpcFileAcquirer(f1.spec)) { EXPECT_EQUAL("my_path", f2.wait_for("my_ref", 60.0)); EXPECT_EQUAL("", f2.wait_for("bogus_ref", 60.0)); } |