Sequence does't apply to sub-groups in common tests?

Dawid Figiel dawid.figiel@REDACTED
Mon Jul 12 15:17:40 CEST 2010


Hi,

I need some feedback, why sequence doesn't apply to sub-groups in common
tests?

example:

This works:

groups() -> [{group1, [sequence], [test1,
                                   test2]}].

If test1 fail then test2 will be skipped.

And this does not work:

groups() -> [{group1, [sequence], [{subgroup1, [], [test1]},
                                   {subgroup2, [], [test2]}]}]

end_per_group(Group, Config) ->
    Status = ?config(tc_group_result, Config),
    case proplists:get_value(failed, Status) of
        [] -> {return_group_result, ok};
        _Failed -> {return_group_result, failed}
    end.

Test1 has failed, so subgroup1 is handled as a failed too, but subgroup2 is
not skipped although we have set up 'sequence'...why ?

According to documentation:

"A failed sub-group (Status == failed) will cause the execution of a
sequence to fail in the same way a test case does."


Any clues ?

-- 
regards,

Dawid


More information about the erlang-questions mailing list