]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/libs/ptr_container/test/ptr_list.cpp
import new upstream nautilus stable release 14.2.8
[ceph.git] / ceph / src / boost / libs / ptr_container / test / ptr_list.cpp
index 92d364d14a0d780953b3be433d0bb057bd75f355..46548bceb3bb1268373c17793123fe84d68cf068 100644 (file)
@@ -57,6 +57,18 @@ void test_list()
     list.push_front( std::unique_ptr<int>( new int(43) ) );
 #endif
     list.reverse();
+    ptr_list<int>::const_iterator it = list.begin();
+    BOOST_CHECK(1 == *it++);
+    BOOST_CHECK(2 == *it++);
+    BOOST_CHECK(0 == *it++);
+    BOOST_CHECK(3 == *it++);
+#ifndef BOOST_NO_AUTO_PTR
+    BOOST_CHECK(42 == *it++);
+#endif
+#ifndef BOOST_NO_CXX11_SMART_PTR
+    BOOST_CHECK(43 == *it++);
+#endif
+    BOOST_CHECK(list.end() == it);
 }
 
 #if defined(BOOST_PTR_CONTAINER_DISABLE_DEPRECATED)