summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--project2/ut/Jamfile.jam1
-rw-r--r--project2/ut/butf_logger.cpp21
2 files changed, 22 insertions, 0 deletions
diff --git a/project2/ut/Jamfile.jam b/project2/ut/Jamfile.jam
index 0c7aa08..dc0d734 100644
--- a/project2/ut/Jamfile.jam
+++ b/project2/ut/Jamfile.jam
@@ -4,6 +4,7 @@ lib p2ut :
[ glob *.cpp ]
:
<library>../common//p2common
+ <library>boost_utf
: :
<define>BOOST_TEST_DYN_LINK
<library>boost_utf
diff --git a/project2/ut/butf_logger.cpp b/project2/ut/butf_logger.cpp
new file mode 100644
index 0000000..c5f45b4
--- /dev/null
+++ b/project2/ut/butf_logger.cpp
@@ -0,0 +1,21 @@
+#include <boost/test/unit_test_log.hpp>
+#include "logger.h"
+#include "options.h"
+
+/// Logger that writes Boost Unit Test Framework messages
+class BoostUTFLogDriver : public LogDriverBase {
+ public:
+ BoostUTFLogDriver()
+ {
+ }
+ void message(int, const char * msg) const
+ {
+ BOOST_TEST_MESSAGE(msg);
+ }
+ static int level;
+};
+
+int BoostUTFLogDriver::level = LOG_DEBUG;
+
+DECLARE_LOGGER_LOADER("boostutf", BoostUTFLogDriver);
+