Boost logo

Boost Users :

Subject: Re: [Boost-users] [boost.test] 0 return code with expected failures?
From: Ahmed Badran (ahmed.badran_at_[hidden])
Date: 2010-04-15 20:47:49


On 3/20/2010 12:32 PM, Gennadiy Rozental wrote:
> Ahmed Badran<ahmed.badran<at> gmail.com> writes:
>> On 3/18/2010 10:56 AM, Ahmed Badran wrote:
>>> On 3/18/2010 12:20 AM, Gennadiy Rozental wrote:
>>>> Ahmed Badran<ahmed.badran<at> gmail.com> writes:
>>>>
>>>>> Is there a way to have the binary return a zero
>>>>> exit code when all the failures are expected and
>>>>> non-zero when some other non-expected failure happens?
>>>>
>>>> What version of Boost are you using? Is this the case for the latest
>>>> release?
>> The same issue happens with 1.42
>
> Can't reproduce the issue. Please try unit_test_example_08 and let me know if
> you see non zero result code.
>
Ahhhh, finally found the difference, example 8 works as I would expect. Turns out that my test case had a BOOST_REQUIRE rather than a BOOST_CHECK (like example 8), so it turns out that a test case that has a BOOST_REQUIRE and is flagged as a known issues still causes a non-zero exit status which is not what I would expect since the test was flagged as a known issue anyway. Is that the intended behavior? Or would you consider revising this behavior in a future release?
I appreciate your help.

Regards,
Ahmed


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