MCPcopy Create free account
hub / github.com/fmtlib/fmt / test_format

Function test_format

test/compile-test.cc:357–361  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

355
356template <size_t max_string_length, typename Char = char, typename... Args>
357consteval auto test_format(auto format, const Args&... args) {
358 test_string<max_string_length, Char> string{};
359 fmt::format_to(string.buffer, format, args...);
360 return string;
361}
362
363TEST(compile_time_formatting_test, bool) {
364 EXPECT_EQ("true", test_format<5>(FMT_COMPILE("{}"), true));

Callers

nothing calls this directly

Calls 1

format_toFunction · 0.50

Tested by

no test coverage detected