tests: avoid deprecated boost headers; define BOOST_TEST_MODULE
Change-Id: Ie1e731e0943e635be36d65ea0dc02c348c17f05a
diff --git a/tests/boost-test.hpp b/tests/boost-test.hpp
index 017a0be..0d4f139 100644
--- a/tests/boost-test.hpp
+++ b/tests/boost-test.hpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
- * Copyright (c) 2014-2018, Regents of the University of California,
+ * Copyright (c) 2014-2019, Regents of the University of California,
* Arizona Board of Regents,
* Colorado State University,
* University Pierre & Marie Curie, Sorbonne University,
@@ -30,7 +30,7 @@
#pragma GCC system_header
#pragma clang system_header
+#define BOOST_TEST_DYN_LINK
#include <boost/test/unit_test.hpp>
-#include <boost/test/output_test_stream.hpp>
#endif // NDN_TOOLS_TESTS_BOOST_TEST_HPP
diff --git a/tests/chunks/consumer.t.cpp b/tests/chunks/consumer.t.cpp
index 671f1ce..dba1c6b 100644
--- a/tests/chunks/consumer.t.cpp
+++ b/tests/chunks/consumer.t.cpp
@@ -32,6 +32,12 @@
#include <ndn-cxx/security/validator-null.hpp>
#include <ndn-cxx/util/dummy-client-face.hpp>
+#if BOOST_VERSION >= 105900
+#include <boost/test/tools/output_test_stream.hpp>
+#else
+#include <boost/test/output_test_stream.hpp>
+#endif
+
namespace ndn {
namespace chunks {
namespace tests {
diff --git a/tests/dump/ndndump.t.cpp b/tests/dump/ndndump.t.cpp
index cd56f12..59a8879 100644
--- a/tests/dump/ndndump.t.cpp
+++ b/tests/dump/ndndump.t.cpp
@@ -30,6 +30,11 @@
#include <netinet/udp.h>
#include <boost/endian/conversion.hpp>
+#if BOOST_VERSION >= 105900
+#include <boost/test/tools/output_test_stream.hpp>
+#else
+#include <boost/test/output_test_stream.hpp>
+#endif
#include <ndn-cxx/encoding/encoding-buffer.hpp>
#include <ndn-cxx/lp/packet.hpp>
diff --git a/tests/main.cpp b/tests/main.cpp
index 3a2a4fb..c111daf 100644
--- a/tests/main.cpp
+++ b/tests/main.cpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014-2015, Regents of the University of California,
+/*
+ * Copyright (c) 2014-2019, Regents of the University of California,
* Arizona Board of Regents,
* Colorado State University,
* University Pierre & Marie Curie, Sorbonne University,
@@ -23,7 +23,6 @@
* ndn-tools, e.g., in COPYING.md file. If not, see <http://www.gnu.org/licenses/>.
*/
-#define BOOST_TEST_MAIN 1
-#define BOOST_TEST_DYN_LINK 1
+#define BOOST_TEST_MODULE ndn-tools Unit Tests
#include "boost-test.hpp"
diff --git a/tests/peek/ndnpeek.t.cpp b/tests/peek/ndnpeek.t.cpp
index 3d72664..0e0840a 100644
--- a/tests/peek/ndnpeek.t.cpp
+++ b/tests/peek/ndnpeek.t.cpp
@@ -24,6 +24,11 @@
#include <ndn-cxx/util/dummy-client-face.hpp>
#include <boost/mpl/vector.hpp>
+#if BOOST_VERSION >= 105900
+#include <boost/test/tools/output_test_stream.hpp>
+#else
+#include <boost/test/output_test_stream.hpp>
+#endif
namespace ndn {
namespace peek {