diff options
author | Qyriad <qyriad@qyriad.me> | 2024-04-10 19:25:30 -0600 |
---|---|---|
committer | Qyriad <qyriad@qyriad.me> | 2024-04-15 23:09:16 +0000 |
commit | 4e68deef809c67ff3d75089d43f0d62017a1122f (patch) | |
tree | a22ea52b85680f16a4ee8da7b41bda6eb12bea2e /tests/unit/libutil | |
parent | 80bbfe20342be13a7320bc5ae5694e3454b61dbb (diff) |
abort with a descriptive message on bad HintFmt usage
Change-Id: Ic2f05572042343a8160fd971394372f5f2706fc4
Diffstat (limited to 'tests/unit/libutil')
-rw-r--r-- | tests/unit/libutil/fmt.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/unit/libutil/fmt.cc b/tests/unit/libutil/fmt.cc index 383a688d3..90bcdfbe4 100644 --- a/tests/unit/libutil/fmt.cc +++ b/tests/unit/libutil/fmt.cc @@ -15,9 +15,9 @@ TEST(HintFmt, arg_count) ASSERT_EQ(HintFmt("%1%", "hello").str(), ANSI_MAGENTA "hello" ANSI_NORMAL); // Argument counts are detected at construction. - ASSERT_THROW(HintFmt("%s %s", 1), boost::io::too_few_args); + ASSERT_DEATH(HintFmt("%s %s", 1), "HintFmt received incorrect"); - ASSERT_THROW(HintFmt("%s", 1, 2), boost::io::too_many_args); + ASSERT_DEATH(HintFmt("%s", 1, 2), "HintFmt received incorrect"); } } |