Simplify test

This commit is contained in:
Victor Zverovich 2023-12-01 08:52:42 -08:00
parent 99b9fbf8ef
commit f575089243

View File

@ -69,10 +69,9 @@ TEST(std_test, thread_id) {
#ifdef __cpp_lib_source_location
TEST(std_test, source_location) {
std::source_location loc = std::source_location::current();
EXPECT_EQ(fmt::format("{}", loc), std::string(loc.file_name()) + ":" +
std::to_string(loc.line()) + ":" +
std::to_string(loc.column()) + ": " +
loc.function_name());
EXPECT_EQ(fmt::format("{}", loc),
fmt::format("{}:{}:{}: {}", loc.file_name(), loc.line(),
loc.column(), loc.function_name()));
}
#endif