From 32516292e15b522bf188e9a1111c19ec797ce6dc Mon Sep 17 00:00:00 2001 From: John Fletcher Date: Wed, 4 Mar 2015 16:51:24 +0000 Subject: [PATCH] lazy_list3_tests Add more tests --- test/function/lazy_list3_tests.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/test/function/lazy_list3_tests.cpp b/test/function/lazy_list3_tests.cpp index 39c1f85..cf18a2b 100644 --- a/test/function/lazy_list3_tests.cpp +++ b/test/function/lazy_list3_tests.cpp @@ -23,8 +23,8 @@ int main() { namespace phx = boost::phoenix; - using boost::phoenix::arg_names::arg1; - using boost::phoenix::arg_names::arg2; + //using boost::phoenix::arg_names::arg1; + //using boost::phoenix::arg_names::arg2; using namespace phx; list l = enum_from(2); @@ -33,11 +33,15 @@ int main() list l2 = enum_from_to(2,10); list ll2 = take(4,l2); list lll2 = take(12,l2); - + list evens = filter(even,l); + list even4 = take(4,evens)(); + BOOST_TEST(last(ll)() == 5); BOOST_TEST(last(lll)() == 13); BOOST_TEST(last(ll2)() == 5); BOOST_TEST(last(lll2)() == 10); - + BOOST_TEST(length(lll2)() == 9); + BOOST_TEST(at(even4,3)() == 8); + return boost::report_errors(); }