Oops accidentally hit send when I was pasting in the two examples. Here is
the other one:

                else:
                    # Some fields contain ints or strings.
                    assert isinstance(z, (int, str)), z.__class__.__name__

On Sun, Jan 12, 2020 at 9:49 AM Brian Theado <[email protected]> wrote:

>
> On Sun, Jan 12, 2020 at 8:18 AM Edward K. Ream <[email protected]>
> wrote:
>
>>
>>
>> On Sat, Jan 11, 2020 at 2:11 PM Brian Theado <[email protected]>
>> wrote:
>>
>> > I have doubts about the following entries you are suppressing: assert,
>> except, raise.
>>
>> Imo, they are fine.  Assert signal that something is seriously wrong
>> with the tool, not the user input.
>>
>
> My suggestion was to allow coverage to report on execution of assert
> statements. It sounds to me like you are responding as if I suggested to
> test assertion failures. Code coverage reporting can't distinguish between
> when the assertion fails and when it doesn't.
>
> I only found 2 instances of assert statements not being covered when I
> change .coveragerc to include asserts and re-ran the tests. In both cases
> they are else clauses which your current tests don't cover.
>
> if e is not None: assert e.lower() == 'utf-8', repr(e)
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/leo-editor/CAO5X8CxOnYpMcTp3zS%2B%2BqgCL2-1tq0PnxU7mB0AXNHKS_SriCA%40mail.gmail.com.

Reply via email to