diff --git a/scrapling/core/custom_types.py b/scrapling/core/custom_types.py index d06ac29..53255be 100644 --- a/scrapling/core/custom_types.py +++ b/scrapling/core/custom_types.py @@ -112,10 +112,10 @@ class TextHandler(str): def get(self, default=None): # pragma: no cover return self - def get_all(self): # pragma: no cover + def getall(self): # pragma: no cover return self - extract = get_all + extract = getall extract_first = get def json(self) -> Dict: @@ -279,7 +279,7 @@ class TextHandlers(List[TextHandler]): return self extract_first = get - get_all = extract + getall = extract class AttributesHandler(Mapping[str, _TextHandlerType]): diff --git a/tests/parser/test_parser_advanced.py b/tests/parser/test_parser_advanced.py index 969ccc3..39829bb 100644 --- a/tests/parser/test_parser_advanced.py +++ b/tests/parser/test_parser_advanced.py @@ -357,7 +357,7 @@ class TestTextHandlerAdvanced: """Test TextHandlers.extract() returns self""" handlers = TextHandlers([TextHandler("a"), TextHandler("b")]) assert handlers.extract() is handlers - assert handlers.get_all() is handlers + assert handlers.getall() is handlers class TestSelectorsAdvanced: