diff options
| author | Lee *!* Clagett <code@leeclagett.com> | 2024-08-27 14:07:52 -0400 |
|---|---|---|
| committer | Lee *!* Clagett <code@leeclagett.com> | 2024-12-19 20:54:22 -0500 |
| commit | 0cd74568d6a7709c82cb12012ec952c8d00d6c96 (patch) | |
| tree | 0f291c5880a92b4ef903f12a92519ca860a099a1 /tests/unit_tests | |
| parent | 58a1d54a4f90a235616ede3f8ebae2b8dca41589 (diff) | |
| download | monzero-core-0cd74568d6a7709c82cb12012ec952c8d00d6c96.tar.gz monzero-core-0cd74568d6a7709c82cb12012ec952c8d00d6c96.tar.xz monzero-core-0cd74568d6a7709c82cb12012ec952c8d00d6c96.zip | |
Cleanup TCP throttling code (performance) + move connection checks
Diffstat (limited to 'tests/unit_tests')
| -rw-r--r-- | tests/unit_tests/node_server.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/unit_tests/node_server.cpp b/tests/unit_tests/node_server.cpp index 584f98f7a..0a1d80073 100644 --- a/tests/unit_tests/node_server.cpp +++ b/tests/unit_tests/node_server.cpp @@ -224,6 +224,18 @@ TEST(ban, subnet) test_core pr_core; cryptonote::t_cryptonote_protocol_handler<test_core> cprotocol(pr_core, NULL); Server server(cprotocol); + { + boost::program_options::options_description opts{}; + Server::init_options(opts); + cryptonote::core::init_options(opts); + + char** args = nullptr; + boost::program_options::variables_map vm; + boost::program_options::store( + boost::program_options::parse_command_line(0, args, opts), vm + ); + server.init(vm); + } cprotocol.set_p2p_endpoint(&server); ASSERT_TRUE(server.block_subnet(MAKE_IPV4_SUBNET(1,2,3,4,24), 10)); |
