From: khizmax Date: Fri, 3 Oct 2014 14:19:49 +0000 (+0400) Subject: add test for TreiberStack::pop_with() X-Git-Tag: v2.0.0~235 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d4f4a65c52ea303adf924320f8c312f80dbbf9c3;p=libcds.git add test for TreiberStack::pop_with() --- diff --git a/tests/test-hdr/stack/hdr_treiber_stack.h b/tests/test-hdr/stack/hdr_treiber_stack.h index 33e43b76..3767be71 100644 --- a/tests/test-hdr/stack/hdr_treiber_stack.h +++ b/tests/test-hdr/stack/hdr_treiber_stack.h @@ -38,7 +38,7 @@ namespace stack { CPPUNIT_ASSERT( stack.pop(v) ); CPPUNIT_ASSERT( v == 3 ); CPPUNIT_ASSERT( !stack.empty() ); - CPPUNIT_ASSERT( stack.pop(v) ); + CPPUNIT_ASSERT( stack.pop_with( [&v]( value_type& src ) { v = src; } ); CPPUNIT_ASSERT( v == 2 ); CPPUNIT_ASSERT( !stack.empty() ); CPPUNIT_ASSERT( stack.pop(v) );