git-svn-id: https://svn.code.sf.net/p/turtle/code/trunk@73 860be788-9bd5-4423-9f1e-828f051e677b
This commit is contained in:
mat007 2009-12-13 19:07:47 +00:00
parent 87335f7ab0
commit f16cd01b18

View file

@ -7,8 +7,7 @@
// //
#include <turtle/mock.hpp> #include <turtle/mock.hpp>
#include <boost/static_assert.hpp> #include <boost/mpl/assert.hpp>
#include <boost/mpl/equal.hpp>
#include <boost/test/auto_unit_test.hpp> #include <boost/test/auto_unit_test.hpp>
#define BOOST_LIB_NAME boost_unit_test_framework #define BOOST_LIB_NAME boost_unit_test_framework
@ -19,12 +18,10 @@ namespace
void f1(); void f1();
int f2( float ); int f2( float );
BOOST_STATIC_ASSERT( (boost::mpl::equal< mock::expectation< void() >, BOOST_MPL_ASSERT(( boost::is_same< mock::expectation< void() >,
mock::expectation< BOOST_TYPEOF( f1 ) > mock::expectation< BOOST_TYPEOF( f1 ) > > ));
>::value) ); BOOST_MPL_ASSERT(( boost::is_same< mock::expectation< int( float ) >,
BOOST_STATIC_ASSERT( (boost::mpl::equal< mock::expectation< int( float ) >, mock::expectation< BOOST_TYPEOF( f2 ) > > ));
mock::expectation< BOOST_TYPEOF( f2 ) >
>::value) );
struct example struct example
{ {
@ -33,7 +30,7 @@ namespace
}; };
BOOST_STATIC_ASSERT( BOOST_STATIC_ASSERT(
(boost::mpl::equal< (boost::is_same<
mock::expectation< void() >, mock::expectation< void() >,
mock::expectation< mock::expectation<
mock::detail::signature< mock::detail::signature<
@ -42,7 +39,7 @@ namespace
> >
>::value) ); >::value) );
BOOST_STATIC_ASSERT( BOOST_STATIC_ASSERT(
(boost::mpl::equal< (boost::is_same<
mock::expectation< float( int ) >, mock::expectation< float( int ) >,
mock::expectation< mock::expectation<
mock::detail::signature< mock::detail::signature<