Skip to content

Commit

Permalink
rpc_test: silence depreceted lambda logger warning
Browse files Browse the repository at this point in the history
Signed-off-by: Botond Dénes <[email protected]>
Message-Id: <[email protected]>
  • Loading branch information
denesb authored and avikivity committed Apr 2, 2020
1 parent 65c1abc commit b1e297d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/unit/rpc_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1134,9 +1134,13 @@ SEASTAR_TEST_CASE(test_loggers) {
proto.set_logger(&log);
logger(dummy_addr, "Hello2");
logger(dummy_addr, log_level::debug, "Hello3");
// We *want* to test the deprecated API, don't spam warnings about it.
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
proto.set_logger([] (const sstring& str) {
log.info("Test: {}", str);
});
#pragma GCC diagnostic pop
logger(dummy_addr, "Hello4");
logger(dummy_addr, log_level::debug, "Hello5");
proto.set_logger(nullptr);
Expand Down

0 comments on commit b1e297d

Please sign in to comment.