Boost logo

Boost Users :

From: Sean Huang (huangsean_at_[hidden])
Date: 2006-03-02 17:46:29


From: "Gennadiy Rozental" <gennadiy.rozental_at_[hidden]>
>
> Unexpected exception is an error for any statement, for any tool. Common
> rule is that execution monitors deals with it (like in case above).
> BOOST_CHECK_THROW checks that particular exception gets thrown. There are
> 3 possible outcome:
> 1. No exception is thrown - error is reported by the tool
> 2. Expected exception is thrown - no error is reported
> 3. Unexpected exception is thrown - error is reported by test case monitor
> (the same would happened if an unexpected exception would happened in any
> other place)
>
> Do you think this particular tool needs to catch all unexpected
> exceptions? But in this case no information for these exceptions would be
> reported.
>
I am too nervous about catching all exceptions and that's why I suggested
providing both versions. One of the advantages of catching all unexpected
exceptions in the macro is it would at lease provide the location of the
exception whereas test case monitor cannot.

Thanks for the prompt reply!

Sean


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net