mirror of
https://github.com/fmtlib/fmt.git
synced 2025-11-02 23:21:45 +01:00
Handle empty format_arg state
This commit is contained in:
@@ -579,8 +579,11 @@ TEST(UtilTest, CustomArg) {
|
||||
}
|
||||
|
||||
TEST(ArgVisitorTest, VisitInvalidArg) {
|
||||
format_arg arg = format_arg();
|
||||
EXPECT_ASSERT(visit(MockVisitor<int>(), arg), "invalid argument type");
|
||||
typedef MockVisitor<fmt::monostate> Visitor;
|
||||
testing::StrictMock<Visitor> visitor;
|
||||
EXPECT_CALL(visitor, visit(_));
|
||||
format_arg arg;
|
||||
visit(visitor, arg);
|
||||
}
|
||||
|
||||
// Tests fmt::internal::count_digits for integer type Int.
|
||||
|
||||
Reference in New Issue
Block a user