mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-28 23:09:23 +02:00
refactor: Return std::optional from GetLogCategory
This commit is contained in:
@@ -165,9 +165,8 @@ BOOST_FIXTURE_TEST_CASE(logging_LogPrintMacros_CategoryName, LogSetup)
|
||||
std::vector<std::pair<BCLog::LogFlags, std::string>> expected_category_names;
|
||||
const auto category_names = SplitString(concatenated_category_names, ',');
|
||||
for (const auto& category_name : category_names) {
|
||||
BCLog::LogFlags category;
|
||||
const auto trimmed_category_name = TrimString(category_name);
|
||||
BOOST_REQUIRE(GetLogCategory(category, trimmed_category_name));
|
||||
const auto category{*Assert(GetLogCategory(trimmed_category_name))};
|
||||
expected_category_names.emplace_back(category, trimmed_category_name);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user