From 08a6f35ec20a9c19d45c62af1cff91d0702246c6 Mon Sep 17 00:00:00 2001 From: Dave Abrahams Date: Sat, 24 Feb 2007 22:40:59 +0000 Subject: [PATCH] Correct testing bugs: either changing assert(...) or BOOST_ASSERT(...) to BOOST_TEST (in my code only) or adding "return boost::report_errors();" where it was clearly missing (and a pure bug, in anyone's code). [SVN r37057] --- test/dict.cpp | 3 +++ test/list.cpp | 2 ++ test/staticmethod.cpp | 1 + test/str.cpp | 3 +++ test/virtual_functions.cpp | 1 + 5 files changed, 10 insertions(+) diff --git a/test/dict.cpp b/test/dict.cpp index 1363c142..375905d6 100644 --- a/test/dict.cpp +++ b/test/dict.cpp @@ -2,6 +2,7 @@ // Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include +#define BOOST_ENABLE_ASSERT_HANDLER #include #include @@ -86,3 +87,5 @@ BOOST_PYTHON_MODULE(dict_ext) def("work_with_dict", work_with_dict); def("test_templates", test_templates); } + +#include "module_tail.cpp" diff --git a/test/list.cpp b/test/list.cpp index 08037fd0..b573dcf7 100644 --- a/test/list.cpp +++ b/test/list.cpp @@ -9,6 +9,7 @@ #include #include #include +#define BOOST_ENABLE_ASSERT_HANDLER #include #include "test_class.hpp" @@ -143,3 +144,4 @@ BOOST_PYTHON_MODULE(list_ext) ; } +#include "module_tail.cpp" diff --git a/test/staticmethod.cpp b/test/staticmethod.cpp index 76728af8..5947e538 100644 --- a/test/staticmethod.cpp +++ b/test/staticmethod.cpp @@ -9,6 +9,7 @@ #include #include #include +#define BOOST_ENABLE_ASSERT_HANDLER #include using namespace boost::python; diff --git a/test/str.cpp b/test/str.cpp index 3e033f85..98e3cc26 100644 --- a/test/str.cpp +++ b/test/str.cpp @@ -7,6 +7,8 @@ #include #include #include +#define BOOST_ENABLE_ASSERT_HANDLER +#include using namespace boost::python; @@ -74,3 +76,4 @@ BOOST_PYTHON_MODULE(str_ext) def("work_with_string",work_with_string); } +#include "module_tail.cpp" diff --git a/test/virtual_functions.cpp b/test/virtual_functions.cpp index 68b58383..d871192a 100644 --- a/test/virtual_functions.cpp +++ b/test/virtual_functions.cpp @@ -11,6 +11,7 @@ #include #include +#define BOOST_ENABLE_ASSERT_HANDLER #include using namespace boost::python;