mirror of
https://github.com/XRPLF/rippled.git
synced 2026-04-29 15:37:57 +00:00
chore: Enable clang-tidy misc checks (#6655)
This commit is contained in:
@@ -53,11 +53,11 @@ private:
|
||||
auto trustedSites = std::make_unique<ValidatorSite>(env.app(), env.journal);
|
||||
|
||||
// load should accept empty sites list
|
||||
std::vector<std::string> emptyCfgSites;
|
||||
std::vector<std::string> const emptyCfgSites;
|
||||
BEAST_EXPECT(trustedSites->load(emptyCfgSites));
|
||||
|
||||
// load should accept valid validator site uris
|
||||
std::vector<std::string> cfgSites(
|
||||
std::vector<std::string> const cfgSites(
|
||||
{"http://ripple.com/",
|
||||
"http://ripple.com/validators",
|
||||
"http://ripple.com:8080/validators",
|
||||
@@ -145,7 +145,7 @@ private:
|
||||
test::StreamSink sink;
|
||||
beast::Journal journal{sink};
|
||||
|
||||
std::vector<std::string> emptyCfgKeys;
|
||||
std::vector<std::string> const emptyCfgKeys;
|
||||
struct publisher
|
||||
{
|
||||
publisher(FetchListConfig const& c) : cfg{c}
|
||||
@@ -181,7 +181,7 @@ private:
|
||||
{{effective2, expires2}},
|
||||
cfg.ssl,
|
||||
cfg.serverVersion);
|
||||
std::string pubHex = strHex(item.server->publisherPublic());
|
||||
std::string const pubHex = strHex(item.server->publisherPublic());
|
||||
cfgPublishers.push_back(pubHex);
|
||||
|
||||
if (item.cfg.failFetch)
|
||||
@@ -337,11 +337,12 @@ private:
|
||||
};
|
||||
{
|
||||
// Create a file with a real validator list
|
||||
detail::FileDirGuard good(*this, "test_val", "vl.txt", detail::realValidatorContents());
|
||||
detail::FileDirGuard const good(
|
||||
*this, "test_val", "vl.txt", detail::realValidatorContents());
|
||||
// Create a file with arbitrary content
|
||||
detail::FileDirGuard hello(*this, "test_val", "helloworld.txt", "Hello, world!");
|
||||
detail::FileDirGuard const hello(*this, "test_val", "helloworld.txt", "Hello, world!");
|
||||
// Create a file with malformed Json
|
||||
detail::FileDirGuard json(
|
||||
detail::FileDirGuard const json(
|
||||
*this, "test_val", "json.txt", R"json({ "version": 2, "extra" : "value" })json");
|
||||
auto const goodPath = fullPath(good);
|
||||
auto const helloPath = fullPath(hello);
|
||||
@@ -362,7 +363,7 @@ public:
|
||||
{
|
||||
testConfigLoad();
|
||||
|
||||
detail::DirGuard good(*this, "test_fetch");
|
||||
detail::DirGuard const good(*this, "test_fetch");
|
||||
for (auto ssl : {true, false})
|
||||
{
|
||||
// fetch single site
|
||||
|
||||
Reference in New Issue
Block a user