diff --git a/src/healthchecks_io/client/_abstract.py b/src/healthchecks_io/client/_abstract.py index 89ecd0a..f253c0a 100644 --- a/src/healthchecks_io/client/_abstract.py +++ b/src/healthchecks_io/client/_abstract.py @@ -44,12 +44,14 @@ class AbstractClient(ABC): self._finalizer = finalize(self, self._finalizer_method) @abstractmethod - def _finalizer_method(self): + def _finalizer_method(self): # pragma: no cover """Finalizer method is called by weakref.finalize when the object is dereferenced to do cleanup of clients.""" pass @abstractmethod - def get_checks(self, tags: Optional[List[str]]) -> List[checks.Check]: + def get_checks( + self, tags: Optional[List[str]] + ) -> List[checks.Check]: # pragma: no cover """Calls the API's /checks/ endpoint to get a list of checks.""" pass diff --git a/tests/client/test_abstract.py b/tests/client/test_abstract.py new file mode 100644 index 0000000..7ba2318 --- /dev/null +++ b/tests/client/test_abstract.py @@ -0,0 +1,10 @@ +from healthchecks_io.client._abstract import AbstractClient + + +def test_abstract_add_url_params(): + AbstractClient.__abstractmethods__ = set() + abstract_client = AbstractClient("test") + url = abstract_client._add_url_params( + "http://test.com/?test=test", {"test": "test2"} + ) + assert url == "http://test.com/?test=test2"