Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion codecov/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ class Config:
MINIMUM_GREEN: decimal.Decimal = decimal.Decimal('100')
MINIMUM_ORANGE: decimal.Decimal = decimal.Decimal('70')
TEST_FRAMEWORK: TestFramework = TestFramework.PYTEST
# TODO: Remove branch coverage and just use the report
BRANCH_COVERAGE: bool = False
MAX_FILES_IN_COMMENT: int = 25
SKIP_COVERED_FILES_IN_REPORT: bool = True
Expand Down
4 changes: 0 additions & 4 deletions codecov/coverage/pytest.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ class PytestCoverageInfo: # pylint: disable=too-many-instance-attributes
missing_lines: int
excluded_lines: int
num_branches: int | None
num_partial_branches: int | None # TODO: Removed this
covered_branches: int | None
missing_branches: int | None
percent_covered: decimal.Decimal
Expand Down Expand Up @@ -80,7 +79,6 @@ def extract_coverage_info(self, data: dict) -> PytestCoverageInfo:
missing_lines=data['missing_lines'],
excluded_lines=data['excluded_lines'],
num_branches=data.get('num_branches'),
num_partial_branches=data.get('num_partial_branches'),
covered_branches=data.get('covered_branches'),
missing_branches=data.get('missing_branches'),
)
Expand Down Expand Up @@ -116,7 +114,6 @@ def extract_info(self, data: dict) -> PytestCoverage:
"missing_lines": 4,
"excluded_lines": 0,
"num_branches": 22,
"num_partial_branches": 4,
"covered_branches": 18,
"missing_branches": 4
},
Expand All @@ -134,7 +131,6 @@ def extract_info(self, data: dict) -> PytestCoverage:
"missing_lines": 1,
"excluded_lines": 0,
"num_branches": 2,
"num_partial_branches": 1,
"covered_branches": 1,
"missing_branches": 1,
},
Expand Down
7 changes: 0 additions & 7 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ def _(code: str, has_branches: bool = True) -> PytestCoverage:
missing_lines=0,
excluded_lines=0,
num_branches=0 if has_branches else None,
num_partial_branches=0 if has_branches else None,
covered_branches=0 if has_branches else None,
missing_branches=0 if has_branches else None,
),
Expand Down Expand Up @@ -89,7 +88,6 @@ def _(code: str, has_branches: bool = True) -> PytestCoverage:
missing_lines=0,
excluded_lines=0,
num_branches=0 if has_branches else None,
num_partial_branches=0 if has_branches else None,
covered_branches=0 if has_branches else None,
missing_branches=0 if has_branches else None,
),
Expand Down Expand Up @@ -136,8 +134,6 @@ def _(code: str, has_branches: bool = True) -> PytestCoverage:
coverage_obj.info.covered_branches += 1
file_coverage.info.missing_branches += 1
coverage_obj.info.missing_branches += 1
file_coverage.info.num_partial_branches += 1
coverage_obj.info.num_partial_branches += 1
elif 'branch covered' in line:
file_coverage.executed_branches.append([line_number, line_number + 1])
file_coverage.info.num_branches += 1
Expand Down Expand Up @@ -234,8 +230,6 @@ def coverage_json():
'missing_lines': 4,
'excluded_lines': 0,
'num_branches': 7,
# Line 5 is partial: one of its two arcs was taken.
'num_partial_branches': 1,
'covered_branches': 4,
'missing_branches': 3,
},
Expand All @@ -254,7 +248,6 @@ def coverage_json():
'missing_lines': 4,
'excluded_lines': 0,
'num_branches': 7,
'num_partial_branches': 1,
'covered_branches': 4,
'missing_branches': 3,
},
Expand Down
2 changes: 0 additions & 2 deletions tests/coverage/test_pytest.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def test_extract_info(self, coverage_json):
missing_lines=4,
excluded_lines=0,
num_branches=7,
num_partial_branches=1,
covered_branches=4,
missing_branches=3,
),
Expand All @@ -54,7 +53,6 @@ def test_extract_info(self, coverage_json):
missing_lines=4,
excluded_lines=0,
num_branches=7,
num_partial_branches=1,
covered_branches=4,
missing_branches=3,
),
Expand Down
Loading