Boost logo

Boost-Commit :

From: chris_at_[hidden]
Date: 2007-09-24 09:21:49


Author: chris_kohlhoff
Date: 2007-09-24 09:21:49 EDT (Mon, 24 Sep 2007)
New Revision: 39505
URL: http://svn.boost.org/trac/boost/changeset/39505

Log:
Output error codes and error messages when a test fails.

Text files modified:
   trunk/libs/asio/test/ip/multicast.cpp | 44 +++++++++---------
   trunk/libs/asio/test/socket_base.cpp | 93 ++++++++++++++++++++-------------------
   2 files changed, 69 insertions(+), 68 deletions(-)

Modified: trunk/libs/asio/test/ip/multicast.cpp
==============================================================================
--- trunk/libs/asio/test/ip/multicast.cpp (original)
+++ trunk/libs/asio/test/ip/multicast.cpp 2007-09-24 09:21:49 EDT (Mon, 24 Sep 2007)
@@ -140,14 +140,14 @@
   {
     ip::multicast::join_group join_group(multicast_address_v4);
     sock_v4.set_option(join_group, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   if (have_v6)
   {
     ip::multicast::join_group join_group(multicast_address_v6);
     sock_v6.set_option(join_group, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   // leave_group class.
@@ -156,14 +156,14 @@
   {
     ip::multicast::leave_group leave_group(multicast_address_v4);
     sock_v4.set_option(leave_group, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   if (have_v6)
   {
     ip::multicast::leave_group leave_group(multicast_address_v6);
     sock_v6.set_option(leave_group, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   // outbound_interface class.
@@ -173,14 +173,14 @@
     ip::multicast::outbound_interface outbound_interface(
         ip::address_v4::loopback());
     sock_v4.set_option(outbound_interface, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   if (have_v6)
   {
     ip::multicast::outbound_interface outbound_interface(1);
     sock_v6.set_option(outbound_interface, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   }
 
   // hops class.
@@ -190,21 +190,21 @@
     ip::multicast::hops hops1(1);
     BOOST_CHECK(hops1.value() == 1);
     sock_v4.set_option(hops1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::hops hops2;
     sock_v4.get_option(hops2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(hops2.value() == 1);
 
     ip::multicast::hops hops3(0);
     BOOST_CHECK(hops3.value() == 0);
     sock_v4.set_option(hops3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::hops hops4;
     sock_v4.get_option(hops4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(hops4.value() == 0);
   }
 
@@ -213,21 +213,21 @@
     ip::multicast::hops hops1(1);
     BOOST_CHECK(hops1.value() == 1);
     sock_v6.set_option(hops1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::hops hops2;
     sock_v6.get_option(hops2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(hops2.value() == 1);
 
     ip::multicast::hops hops3(0);
     BOOST_CHECK(hops3.value() == 0);
     sock_v6.set_option(hops3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::hops hops4;
     sock_v6.get_option(hops4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(hops4.value() == 0);
   }
 
@@ -240,11 +240,11 @@
     BOOST_CHECK(static_cast<bool>(enable_loopback1));
     BOOST_CHECK(!!enable_loopback1);
     sock_v4.set_option(enable_loopback1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::enable_loopback enable_loopback2;
     sock_v4.get_option(enable_loopback2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(enable_loopback2.value());
     BOOST_CHECK(static_cast<bool>(enable_loopback2));
     BOOST_CHECK(!!enable_loopback2);
@@ -254,11 +254,11 @@
     BOOST_CHECK(!static_cast<bool>(enable_loopback3));
     BOOST_CHECK(!enable_loopback3);
     sock_v4.set_option(enable_loopback3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::enable_loopback enable_loopback4;
     sock_v4.get_option(enable_loopback4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(!enable_loopback4.value());
     BOOST_CHECK(!static_cast<bool>(enable_loopback4));
     BOOST_CHECK(!enable_loopback4);
@@ -271,11 +271,11 @@
     BOOST_CHECK(static_cast<bool>(enable_loopback1));
     BOOST_CHECK(!!enable_loopback1);
     sock_v6.set_option(enable_loopback1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::enable_loopback enable_loopback2;
     sock_v6.get_option(enable_loopback2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(enable_loopback2.value());
     BOOST_CHECK(static_cast<bool>(enable_loopback2));
     BOOST_CHECK(!!enable_loopback2);
@@ -285,11 +285,11 @@
     BOOST_CHECK(!static_cast<bool>(enable_loopback3));
     BOOST_CHECK(!enable_loopback3);
     sock_v6.set_option(enable_loopback3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
     ip::multicast::enable_loopback enable_loopback4;
     sock_v6.get_option(enable_loopback4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
     BOOST_CHECK(!enable_loopback4.value());
     BOOST_CHECK(!static_cast<bool>(enable_loopback4));
     BOOST_CHECK(!enable_loopback4);

Modified: trunk/libs/asio/test/socket_base.cpp
==============================================================================
--- trunk/libs/asio/test/socket_base.cpp (original)
+++ trunk/libs/asio/test/socket_base.cpp 2007-09-24 09:21:49 EDT (Mon, 24 Sep 2007)
@@ -210,11 +210,11 @@
   BOOST_CHECK(static_cast<bool>(broadcast1));
   BOOST_CHECK(!!broadcast1);
   udp_sock.set_option(broadcast1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::broadcast broadcast2;
   udp_sock.get_option(broadcast2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(broadcast2.value());
   BOOST_CHECK(static_cast<bool>(broadcast2));
   BOOST_CHECK(!!broadcast2);
@@ -224,11 +224,11 @@
   BOOST_CHECK(!static_cast<bool>(broadcast3));
   BOOST_CHECK(!broadcast3);
   udp_sock.set_option(broadcast3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::broadcast broadcast4;
   udp_sock.get_option(broadcast4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!broadcast4.value());
   BOOST_CHECK(!static_cast<bool>(broadcast4));
   BOOST_CHECK(!broadcast4);
@@ -246,12 +246,12 @@
   BOOST_CHECK(!ec || not_root);
   BOOST_WARN_MESSAGE(!ec, "Must be root to set debug socket option");
 #else // defined(__linux__)
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif // defined(__linux__)
 
   socket_base::debug debug2;
   udp_sock.get_option(debug2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #if defined(__linux__)
   BOOST_CHECK(debug2.value() || not_root);
   BOOST_CHECK(static_cast<bool>(debug2) || not_root);
@@ -270,12 +270,12 @@
 #if defined(__linux__)
   BOOST_CHECK(!ec || not_root);
 #else // defined(__linux__)
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif // defined(__linux__)
 
   socket_base::debug debug4;
   udp_sock.get_option(debug4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #if defined(__linux__)
   BOOST_CHECK(!debug4.value() || not_root);
   BOOST_CHECK(!static_cast<bool>(debug4) || not_root);
@@ -293,10 +293,11 @@
   BOOST_CHECK(static_cast<bool>(do_not_route1));
   BOOST_CHECK(!!do_not_route1);
   udp_sock.set_option(do_not_route1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::do_not_route do_not_route2;
   udp_sock.get_option(do_not_route2, ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(do_not_route2.value());
   BOOST_CHECK(static_cast<bool>(do_not_route2));
   BOOST_CHECK(!!do_not_route2);
@@ -306,11 +307,11 @@
   BOOST_CHECK(!static_cast<bool>(do_not_route3));
   BOOST_CHECK(!do_not_route3);
   udp_sock.set_option(do_not_route3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::do_not_route do_not_route4;
   udp_sock.get_option(do_not_route4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!do_not_route4.value());
   BOOST_CHECK(!static_cast<bool>(do_not_route4));
   BOOST_CHECK(!do_not_route4);
@@ -322,11 +323,11 @@
   BOOST_CHECK(static_cast<bool>(keep_alive1));
   BOOST_CHECK(!!keep_alive1);
   tcp_sock.set_option(keep_alive1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::keep_alive keep_alive2;
   tcp_sock.get_option(keep_alive2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(keep_alive2.value());
   BOOST_CHECK(static_cast<bool>(keep_alive2));
   BOOST_CHECK(!!keep_alive2);
@@ -336,11 +337,11 @@
   BOOST_CHECK(!static_cast<bool>(keep_alive3));
   BOOST_CHECK(!keep_alive3);
   tcp_sock.set_option(keep_alive3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::keep_alive keep_alive4;
   tcp_sock.get_option(keep_alive4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!keep_alive4.value());
   BOOST_CHECK(!static_cast<bool>(keep_alive4));
   BOOST_CHECK(!keep_alive4);
@@ -350,21 +351,21 @@
   socket_base::send_buffer_size send_buffer_size1(4096);
   BOOST_CHECK(send_buffer_size1.value() == 4096);
   tcp_sock.set_option(send_buffer_size1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::send_buffer_size send_buffer_size2;
   tcp_sock.get_option(send_buffer_size2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(send_buffer_size2.value() == 4096);
 
   socket_base::send_buffer_size send_buffer_size3(16384);
   BOOST_CHECK(send_buffer_size3.value() == 16384);
   tcp_sock.set_option(send_buffer_size3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::send_buffer_size send_buffer_size4;
   tcp_sock.get_option(send_buffer_size4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(send_buffer_size4.value() == 16384);
 
   // send_low_watermark class.
@@ -375,7 +376,7 @@
 #if defined(WIN32) || defined(__linux__) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Linux, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif
 
   socket_base::send_low_watermark send_low_watermark2;
@@ -385,7 +386,7 @@
 #elif defined(__linux__)
   BOOST_CHECK(!ec); // Not supported on Linux but can get value.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(send_low_watermark2.value() == 4096);
 #endif
 
@@ -395,7 +396,7 @@
 #if defined(WIN32) || defined(__linux__) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Linux, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif
 
   socket_base::send_low_watermark send_low_watermark4;
@@ -405,7 +406,7 @@
 #elif defined(__linux__)
   BOOST_CHECK(!ec); // Not supported on Linux but can get value.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(send_low_watermark4.value() == 8192);
 #endif
 
@@ -414,21 +415,21 @@
   socket_base::receive_buffer_size receive_buffer_size1(4096);
   BOOST_CHECK(receive_buffer_size1.value() == 4096);
   tcp_sock.set_option(receive_buffer_size1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::receive_buffer_size receive_buffer_size2;
   tcp_sock.get_option(receive_buffer_size2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(receive_buffer_size2.value() == 4096);
 
   socket_base::receive_buffer_size receive_buffer_size3(16384);
   BOOST_CHECK(receive_buffer_size3.value() == 16384);
   tcp_sock.set_option(receive_buffer_size3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::receive_buffer_size receive_buffer_size4;
   tcp_sock.get_option(receive_buffer_size4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(receive_buffer_size4.value() == 16384);
 
   // receive_low_watermark class.
@@ -439,7 +440,7 @@
 #if defined(WIN32) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif
 
   socket_base::receive_low_watermark receive_low_watermark2;
@@ -447,7 +448,7 @@
 #if defined(WIN32) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(receive_low_watermark2.value() == 4096);
 #endif
 
@@ -457,7 +458,7 @@
 #if defined(WIN32) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 #endif
 
   socket_base::receive_low_watermark receive_low_watermark4;
@@ -465,7 +466,7 @@
 #if defined(WIN32) || defined(__sun) || defined(__hpux)
   BOOST_CHECK(!!ec); // Not supported on Windows, Solaris or HP-UX.
 #else
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(receive_low_watermark4.value() == 8192);
 #endif
 
@@ -476,11 +477,11 @@
   BOOST_CHECK(static_cast<bool>(reuse_address1));
   BOOST_CHECK(!!reuse_address1);
   udp_sock.set_option(reuse_address1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::reuse_address reuse_address2;
   udp_sock.get_option(reuse_address2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(reuse_address2.value());
   BOOST_CHECK(static_cast<bool>(reuse_address2));
   BOOST_CHECK(!!reuse_address2);
@@ -490,11 +491,11 @@
   BOOST_CHECK(!static_cast<bool>(reuse_address3));
   BOOST_CHECK(!reuse_address3);
   udp_sock.set_option(reuse_address3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::reuse_address reuse_address4;
   udp_sock.get_option(reuse_address4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!reuse_address4.value());
   BOOST_CHECK(!static_cast<bool>(reuse_address4));
   BOOST_CHECK(!reuse_address4);
@@ -505,11 +506,11 @@
   BOOST_CHECK(linger1.enabled());
   BOOST_CHECK(linger1.timeout() == 60);
   tcp_sock.set_option(linger1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::linger linger2;
   tcp_sock.get_option(linger2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(linger2.enabled());
   BOOST_CHECK(linger2.timeout() == 60);
 
@@ -517,11 +518,11 @@
   BOOST_CHECK(!linger3.enabled());
   BOOST_CHECK(linger3.timeout() == 0);
   tcp_sock.set_option(linger3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::linger linger4;
   tcp_sock.get_option(linger4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!linger4.enabled());
 
   // enable_connection_aborted class.
@@ -531,11 +532,11 @@
   BOOST_CHECK(static_cast<bool>(enable_connection_aborted1));
   BOOST_CHECK(!!enable_connection_aborted1);
   tcp_acceptor.set_option(enable_connection_aborted1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::enable_connection_aborted enable_connection_aborted2;
   tcp_acceptor.get_option(enable_connection_aborted2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(enable_connection_aborted2.value());
   BOOST_CHECK(static_cast<bool>(enable_connection_aborted2));
   BOOST_CHECK(!!enable_connection_aborted2);
@@ -545,11 +546,11 @@
   BOOST_CHECK(!static_cast<bool>(enable_connection_aborted3));
   BOOST_CHECK(!enable_connection_aborted3);
   tcp_acceptor.set_option(enable_connection_aborted3, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::enable_connection_aborted enable_connection_aborted4;
   tcp_acceptor.get_option(enable_connection_aborted4, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
   BOOST_CHECK(!enable_connection_aborted4.value());
   BOOST_CHECK(!static_cast<bool>(enable_connection_aborted4));
   BOOST_CHECK(!enable_connection_aborted4);
@@ -558,17 +559,17 @@
 
   socket_base::non_blocking_io non_blocking_io1(true);
   tcp_sock.io_control(non_blocking_io1, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   socket_base::non_blocking_io non_blocking_io2(false);
   tcp_sock.io_control(non_blocking_io2, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 
   // bytes_readable class.
 
   socket_base::bytes_readable bytes_readable;
   udp_sock.io_control(bytes_readable, ec);
- BOOST_CHECK(!ec);
+ BOOST_CHECK_MESSAGE(!ec, ec.value() << ", " << ec.message());
 }
 
 } // namespace socket_base_runtime


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk