Skip to content

Commit

Permalink
Fix coverage configuration
Browse files Browse the repository at this point in the history
Exclude line of TYPE_CHECKING, and avoid using too many exclude patterns (unsafe).
  • Loading branch information
alegonz committed Jan 11, 2020
1 parent 880e421 commit 1c1c6a8
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 7 deletions.
4 changes: 0 additions & 4 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ parallel = True
[report]
exclude_lines =
pragma: no cover
except ImportError
raise ImportError
raise NotImplementedError
return NotImplemented

fail_under = 90
show_missing = True
2 changes: 1 addition & 1 deletion baikal/_core/data_placeholder.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,6 @@ def __repr__(self):
def __lt__(self, other):
if self.__class__ is other.__class__:
return self._name < other.name
return NotImplemented
return NotImplemented # pragma: no cover

# TODO: Use functools.total_ordering and follow best practices
2 changes: 1 addition & 1 deletion baikal/_core/step.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ class Step(_StepBase):
>>> logreg = LogisticRegression(C=2.0)
"""

if TYPE_CHECKING:
if TYPE_CHECKING: # pragma: no cover

def fit(self, X, y, **fit_params):
return self
Expand Down
2 changes: 1 addition & 1 deletion baikal/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

try:
import pydot
except ImportError:
except ImportError: # pragma: no cover
raise ImportError(
"Could not import pydot package."
"You can install with `pip install pydot` or"
Expand Down

0 comments on commit 1c1c6a8

Please sign in to comment.