Boost logo

Boost Users :

Subject: Re: [Boost-users] [Test] Message from unexpected exceptions
From: Leo Carreon (lcarreon_at_[hidden])
Date: 2017-05-15 23:25:20

My exception is one derived from std::runtime_error.

-----Original Message-----
From: Raffi Enficiaud via Boost-users
Sent: Monday, May 15, 2017 7:30 PM
To: boost-users_at_[hidden]
Cc: Raffi Enficiaud
Subject: Re: [Boost-users] [Test] Message from unexpected exceptions

Le 11.05.17 à 09:43, Leo Carreon via Boost-users a écrit :
> Hi,
> Is there a way of configuring Boost.Test to display the message from
> unexpected exceptions?
> I’m asking because at the moment whenever an unexpected exception is
> encountered by Boost.Test, it displays the type of the exception but not
> the message that goes with it making it more difficult to track down
> where the exception came from. If apart from the type of the exception
> the exception message is included, it could quicken the resolution of
> the issue.
> Kind regards,
> Leo

Normally it does, if your exception is one of the known type. See
execution_monitor.ipp lines 1239-- (including the snippet below,
restricted to "std::exception"'s)

What is the type of your exception?



     CATCH_AND_REPORT_STD_EXCEPTION( std::bad_cast )
     CATCH_AND_REPORT_STD_EXCEPTION( std::bad_typeid )
     CATCH_AND_REPORT_STD_EXCEPTION( std::bad_cast )
     CATCH_AND_REPORT_STD_EXCEPTION( std::bad_typeid )

     CATCH_AND_REPORT_STD_EXCEPTION( std::bad_exception )
     CATCH_AND_REPORT_STD_EXCEPTION( std::domain_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::invalid_argument )
     CATCH_AND_REPORT_STD_EXCEPTION( std::length_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::out_of_range )
     CATCH_AND_REPORT_STD_EXCEPTION( std::range_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::overflow_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::underflow_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::logic_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::runtime_error )
     CATCH_AND_REPORT_STD_EXCEPTION( std::exception )

Boost-users mailing list

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at