From 8aa007af3b4eb5105866d6f0969bcbb6dde984dc Mon Sep 17 00:00:00 2001 From: mat007 Date: Sun, 2 Sep 2012 21:30:45 +0000 Subject: [PATCH] Added tests to ensure proper support for boost::result_of git-svn-id: https://svn.code.sf.net/p/turtle/code/trunk@552 860be788-9bd5-4423-9f1e-828f051e677b --- test/detail/test_function.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/test/detail/test_function.cpp b/test/detail/test_function.cpp index 70ab4fc..fa24012 100644 --- a/test/detail/test_function.cpp +++ b/test/detail/test_function.cpp @@ -13,6 +13,8 @@ #include #define BOOST_LIB_NAME boost_unit_test_framework #include +#include +#include #include #include @@ -21,6 +23,15 @@ namespace { boost::function< void() > static_f; + + BOOST_MPL_ASSERT(( + boost::is_same< void, boost::result_of< mock::detail::function< void() >() >::type > )); + BOOST_MPL_ASSERT(( + boost::is_same< int, boost::result_of< mock::detail::function< int() >() >::type > )); + BOOST_MPL_ASSERT(( + boost::is_same< void, boost::result_of< mock::detail::function< void( float ) >( float ) >::type > )); + BOOST_MPL_ASSERT(( + boost::is_same< int, boost::result_of< mock::detail::function< int( float ) >( float ) >::type > )); } // functor