ATF-devel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: xfail: expected failures

On Sun, Jun 27, 2010 at 10:49 PM, Garrett Cooper <> 
>> The rationale I have in mind is: you are always expecting a test case
>> to pass; correct? So that's the default behavior.  You can change the
>> "expect" behavior to something else (like expect failure, expect
>> crash, etc.).  But if you want to go back to the regular behavior (for
>> cleanup steps, or for some othe reason), then you just "expect pass".
>    Maybe there should be an ability to reset the expectations to the
> default :) (or maybe just change the expectations to any arbitrary
> state)?

Resetting the expectations to the default is what atf_tc_expect_pass
does.  And to set them to arbitrary state, you use the other
atf_tc_expect_* functions.  Take a look at for
details on all cases and examples.

And, by the way, I have just finished implementing what is documented
in that page; you can check out the repository and give it a look
(surprisingly, I even remembered to document the new features :-P).  I
need to add to add one extra scenario, "expected_timeout", and 0.10
will be ready for release -- it has way too many changes already :-)

Julio Merino

Home | Main Index | Thread Index | Old Index