|
@@ -14,6 +14,9 @@
|
|
|
|
|
|
#include "config.h"
|
|
#include "config.h"
|
|
#include <gtest/gtest.h>
|
|
#include <gtest/gtest.h>
|
|
|
|
+#ifdef EXPECT_ABORT
|
|
|
|
+#include <testutils/resource.h>
|
|
|
|
+#endif /* EXPECT_ABORT */
|
|
#include <log/log_formatter.h>
|
|
#include <log/log_formatter.h>
|
|
#include <log/logger_level.h>
|
|
#include <log/logger_level.h>
|
|
|
|
|
|
@@ -102,11 +105,13 @@ TEST_F(FormatterTest, multiArg) {
|
|
// don't match number of arguments. This causes it to abort.
|
|
// don't match number of arguments. This causes it to abort.
|
|
TEST_F(FormatterTest, mismatchedPlaceholders) {
|
|
TEST_F(FormatterTest, mismatchedPlaceholders) {
|
|
EXPECT_ABORT({
|
|
EXPECT_ABORT({
|
|
|
|
+ isc::testutils::dontCreateCoreDumps();
|
|
Formatter(isc::log::INFO, s("Missing the first %2"), this).arg("missing").arg("argument");
|
|
Formatter(isc::log::INFO, s("Missing the first %2"), this).arg("missing").arg("argument");
|
|
}, ".*");
|
|
}, ".*");
|
|
|
|
|
|
EXPECT_ABORT({
|
|
EXPECT_ABORT({
|
|
- Formatter(isc::log::INFO, s("Too many arguments in %1 %2"), this).arg("only one");
|
|
|
|
|
|
+ isc::testutils::dontCreateCoreDumps();
|
|
|
|
+ Formatter(isc::log::INFO, s("Too many arguments in %1 %2"), this).arg("only one");
|
|
}, ".*");
|
|
}, ".*");
|
|
}
|
|
}
|
|
#endif /* EXPECT_ABORT */
|
|
#endif /* EXPECT_ABORT */
|