Changeset 3375


Ignore:
Timestamp:
Feb 11, 2015, 10:25:39 AM (8 years ago)
Author:
Peter
Message:

extend test

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/iterator.cc

    r3374 r3375  
    33/*
    44  Copyright (C) 2007, 2008 Jari Häkkinen, Peter Johansson, Markus Ringnér
    5   Copyright (C) 2009, 2010, 2012, 2013, 2014 Peter Johansson
     5  Copyright (C) 2009, 2010, 2012, 2013, 2014, 2015 Peter Johansson
    66
    77  This file is part of the yat library, http://dev.thep.lu.se/yat
     
    4848#include <boost/iterator/iterator_traits.hpp>
    4949#include <boost/iterator/transform_iterator.hpp>
     50#include <boost/static_assert.hpp>
     51#include <boost/type_traits.hpp>
    5052
    5153#include <algorithm>
     
    364366    // test that boost trait class works
    365367    typedef boost::iterator_value<I>::type value_type;
     368    // test that value type is DataWeight
     369    using utility::DataWeight;
     370    BOOST_STATIC_ASSERT((boost::is_same<value_type, DataWeight>::type::value));
    366371    theplu::yat::utility::weighted_iterator_traits<I>::type tag;
    367372    test::avoid_compiler_warning(tag);
     
    372377    // test that boost trait class works
    373378    typedef boost::iterator_value<I>::type value_type;
     379    // test that value type is double
     380    BOOST_STATIC_ASSERT((boost::is_same<value_type, double>::type::value));
    374381    theplu::yat::utility::weighted_iterator_traits<I>::type tag;
    375382    test::avoid_compiler_warning(tag);
Note: See TracChangeset for help on using the changeset viewer.