mirror of
https://github.com/XRPLF/rippled.git
synced 2026-06-04 09:16:47 +00:00
chore: Enable clang-tidy misc checks (#6655)
This commit is contained in:
@@ -572,7 +572,7 @@ class ServerStatus_test : public beast::unit_test::suite, public beast::test::en
|
||||
// for zero limit, pick an arbitrary nonzero number of clients - all
|
||||
// should connect fine.
|
||||
|
||||
int testTo = (limit == 0) ? 50 : limit + 1;
|
||||
int const testTo = (limit == 0) ? 50 : limit + 1;
|
||||
while (connectionCount < testTo)
|
||||
{
|
||||
clients.emplace_back(
|
||||
@@ -1106,7 +1106,7 @@ class ServerStatus_test : public beast::unit_test::suite, public beast::test::en
|
||||
boost::system::error_code ec;
|
||||
doHTTPRequest(env, yield, false, resp, ec);
|
||||
BEAST_EXPECT(resp.result() == boost::beast::http::status::internal_server_error);
|
||||
std::regex body{"Server cannot accept clients"};
|
||||
std::regex const body{"Server cannot accept clients"};
|
||||
BEAST_EXPECT(std::regex_search(resp.body(), body));
|
||||
}
|
||||
|
||||
|
||||
@@ -282,7 +282,7 @@ public:
|
||||
TestSink sink{*this};
|
||||
TestThread thread;
|
||||
sink.threshold(beast::severities::Severity::kAll);
|
||||
beast::Journal journal{sink};
|
||||
beast::Journal const journal{sink};
|
||||
TestHandler handler;
|
||||
auto s = make_Server(handler, thread.get_io_context(), journal);
|
||||
std::vector<Port> serverPort(1);
|
||||
@@ -377,7 +377,7 @@ public:
|
||||
std::string messages;
|
||||
|
||||
except([&] {
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
(*cfg).deprecatedClearSection("port_rpc");
|
||||
@@ -388,7 +388,7 @@ public:
|
||||
BEAST_EXPECT(messages.find("Missing 'ip' in [port_rpc]") != std::string::npos);
|
||||
|
||||
except([&] {
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
(*cfg).deprecatedClearSection("port_rpc");
|
||||
@@ -400,7 +400,7 @@ public:
|
||||
BEAST_EXPECT(messages.find("Missing 'port' in [port_rpc]") != std::string::npos);
|
||||
|
||||
except([&] {
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
(*cfg).deprecatedClearSection("port_rpc");
|
||||
@@ -414,7 +414,7 @@ public:
|
||||
messages.find("Invalid value '0' for key 'port' in [port_rpc]") == std::string::npos);
|
||||
|
||||
except([&] {
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
(*cfg)["server"].set("port", "0");
|
||||
@@ -426,7 +426,7 @@ public:
|
||||
messages.find("Invalid value '0' for key 'port' in [server]") != std::string::npos);
|
||||
|
||||
except([&] {
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
(*cfg).deprecatedClearSection("port_rpc");
|
||||
@@ -442,7 +442,7 @@ public:
|
||||
except([&] // this creates a standard test config without the server
|
||||
// section
|
||||
{
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
cfg = std::make_unique<Config>();
|
||||
@@ -471,7 +471,7 @@ public:
|
||||
except([&] // this creates a standard test config without some of the
|
||||
// port sections
|
||||
{
|
||||
Env env{
|
||||
Env const env{
|
||||
*this,
|
||||
envconfig([](std::unique_ptr<Config> cfg) {
|
||||
cfg = std::make_unique<Config>();
|
||||
|
||||
Reference in New Issue
Block a user