Open
Description
In #6653 consecutive
was added, which allows to ensure that the subset of lines is matched consecutively.
However, it would also be useful to have a mode that ensures that all expected
lines are in the output, e.g. complete=True
: LineMatcher(["unexpected", "1", "2", "3"]).fnmatch_lines(["1", "2", "3"], complete=True)
should fail then (since "unexpected" was not asserted).
Given that consecutive
has not been released and that it overlaps (since complete
would imply consecutive
) it might be worth to change this into a more generic mode
argument.