Skip to content

100% coverage is not 100% #203

@arcivanov

Description

@arcivanov

With branch coverage being introduced there is a curious case of 100% code coverage possible without 100% branch coverage.

Whenever the following code is encountered:

    if a:
       pass

it's possible to achieve 100% coverage in the unit test by setting a to True, while never testing the behaviors when a is False. This needs to be rectified, possibly by adding a property specifying a separate branch coverage threshold and enforcing it separately from and in addition to line coverage.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions