CPPUNIT_ASSERT( !gp.empty());
CPPUNIT_CHECK( gp->first == nKey );
CPPUNIT_CHECK( gp->second.m_val == nKey * 2 );
+ gp.release();
gp = m.extract( nKey );
CPPUNIT_ASSERT( gp );
CPPUNIT_ASSERT( !gp.empty());
CPPUNIT_CHECK( gp->first == nKey );
CPPUNIT_CHECK( gp->second.m_val == nKey * 2 );
+ gp.release();
gp = m.get( nKey );
CPPUNIT_CHECK( !gp );
CPPUNIT_ASSERT( !gp.empty());
CPPUNIT_CHECK( gp->first == nKey );
CPPUNIT_CHECK( gp->second.m_val == nKey * 2 );
+ gp.release();
gp = m.extract_with( wrapped_item( nKey ), wrapped_less());
CPPUNIT_ASSERT( gp );
CPPUNIT_ASSERT( !gp.empty());
CPPUNIT_CHECK( gp->first == nKey );
CPPUNIT_CHECK( gp->second.m_val == nKey * 2 );
+ gp.release();
gp = m.get_with( wrapped_item( nKey ), wrapped_less() );
CPPUNIT_CHECK( !gp );
gp.release();
CPPUNIT_CHECK( gp.empty());
}
- CPPUNIT_CHECK( m.extract_max());
+ CPPUNIT_CHECK( !m.extract_max());
CPPUNIT_CHECK( gp.empty());
CPPUNIT_ASSERT( m.empty());
}
CPPUNIT_ASSERT( it->second.m_val == 200 );
CPPUNIT_ASSERT( m.find(55) == m.end() );
- it = m.insert_key( 55, insert_functor<Map>() );
+ it = m.insert_with( 55, insert_functor<Map>() );
CPPUNIT_ASSERT( it != m.end() );
CPPUNIT_ASSERT( !m.empty() );
CPPUNIT_ASSERT( check_size( m, 3 ));
CPPUNIT_ASSERT( m.insert( 55 ) == m.end() );
CPPUNIT_ASSERT( m.insert( 55, 10 ) == m.end() );
- CPPUNIT_ASSERT( m.insert_key( 55, insert_functor<Map>()) == m.end() );
+ CPPUNIT_ASSERT( m.insert_with( 55, insert_functor<Map>()) == m.end() );
CPPUNIT_ASSERT( m.find(10) != m.end() );
std::pair<iterator, bool> ensureResult = m.ensure( 10 );