Il 17/06/2014 14:21, Andrew Jones ha scritto:
would look better as
report(msg1, cond1) -> FAIL
report_skip(msg2, !cond1, cond1 && cond2) -> SKIP
report_skip(msg3, !cond1, cond1 && cond3) -> SKIP
I think a lot of the time there is other code before the report that you
want to skip. Is anything more a "report_skip(msg1);" (that print a
SKIP message) that useful? So you can do
if (!(msr & 0x1000) {
report_skip("Frob bit 12 of msr");
return;
}
Unless what you really want is not a SKIP but an expected failure, then
I agree with the idea. Something like
report_xfail(msg2, cond1, cond2)
would print:
PASS if cond1 = false, cond2 = true
FAIL if cond1 = false, cond2 = false
XPASS if cond1 = true, cond2 = true
XFAIL if cond1 = true, cond2 = false
An XPASS would ultimately exit with status 1, just like a FAIL.
Paolo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html