Provide a regex mechanism to silence "while True:" branch warnings

Issue #113 resolved
Ned Batchelder repo owner created an issue

The branch measurement doesn't understand that "while True:" (and similar statements) won't take both branches.

Similar to the exclude regex, provide a configurablee regex that matches lines which will not take all their possible branches.

It should default to include "while True" and "while 1", and maybe some others.

Comments (4)

  1. Christian Heimes

    I like to see this feature in the next release of coverage. If you point me to the right code, I could implement the mechanism for you.

  2. Log in to comment