]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/numeric/odeint/test/is_pair.cpp
3 libs/numeric/odeint/test/is_pair.cpp
6 This file tests the is_pair meta-function.
9 Copyright 2011-2012 Karsten Ahnert
10 Copyright 2011-2012 Mario Mulansky
12 Distributed under the Boost Software License, Version 1.0.
13 (See accompanying file LICENSE_1_0.txt or
14 copy at http://www.boost.org/LICENSE_1_0.txt)
17 #define BOOST_TEST_MODULE odeint_is_pair
21 #include <boost/test/unit_test.hpp>
22 #include <boost/static_assert.hpp>
24 #include <boost/numeric/odeint/util/is_pair.hpp>
26 using namespace boost::numeric::odeint
;
30 BOOST_AUTO_TEST_SUITE( is_pair_test
)
32 BOOST_AUTO_TEST_CASE( test_is_pair
)
34 typedef std::pair
< int , int > type1
;
35 typedef std::pair
< int& , int > type2
;
36 typedef std::pair
< int , int& > type3
;
37 typedef std::pair
< int& , int& > type4
;
38 typedef std::pair
< const int , int > type5
;
39 typedef std::pair
< const int& , int > type6
;
41 BOOST_STATIC_ASSERT(( is_pair
< type1
>::value
));
42 BOOST_STATIC_ASSERT(( is_pair
< type2
>::value
));
43 BOOST_STATIC_ASSERT(( is_pair
< type3
>::value
));
44 BOOST_STATIC_ASSERT(( is_pair
< type4
>::value
));
45 BOOST_STATIC_ASSERT(( is_pair
< type5
>::value
));
46 BOOST_STATIC_ASSERT(( is_pair
< type6
>::value
));
49 BOOST_AUTO_TEST_SUITE_END()