[Test] Did This Pass, Or Didn't it?
Here is the Boost Test assertion: BOOST_CHECK_EXCEPTION(dummyOpr->setOperand(emptyValue), DiGSE::fail, fail_msg); Here is the test execution log message: info: check 'incorrect exception DiGSE::fail is caught' has passed I have only one exception: *DiGSE::fail* (derived from *std::exception*). It is the /only /exception that appears in the *BOOST_CHECK_EXCEPTION()* assertions. So, what does "incorrect exception *DiGSE::fail*" mean? If *DiGSE::fail* was caught, then that part is correct. If the message means that some /other/ exception was caught, then this is a Really Poor way of phrasing that information. Or, did the predicate return *false* (which, in my case, means the exception message is wrong)? But if the wrong exception was caught /or/ the predicate returned *false*, then why was the assertion declared "has passed"? Merrill Cornish
Le 15/07/15 04:47, Merrill Cornish a écrit :
Here is the Boost Test assertion:
BOOST_CHECK_EXCEPTION(dummyOpr->setOperand(emptyValue), DiGSE::fail, fail_msg);
Here is the test execution log message:
info: check 'incorrect exception DiGSE::fail is caught' has passed
I have only one exception: *DiGSE::fail* (derived from *std::exception*). It is the /only /exception that appears in the *BOOST_CHECK_EXCEPTION()* assertions. So, what does "incorrect exception *DiGSE::fail*" mean? If *DiGSE::fail* was caught, then that part is correct. If the message means that some /other/ exception was caught, then this is a Really Poor way of phrasing that information.
Or, did the predicate return *false* (which, in my case, means the exception message is wrong)?
But if the wrong exception was caught /or/ the predicate returned *false*, then why was the assertion declared "has passed"?
Merrill Cornish
Hi, We will rephrase that in a better way. Would you mind creating a ticket for the boost.test component (so that we do not forget to address it)? https://svn.boost.org/trac/boost Thanks, Raffi
participants (2)
-
Merrill Cornish
-
Raffi Enficiaud