Repository: brazilian-utils/brutils-python (python)

Issue:
Add `parse_cpf` method
To map `sieve` to `parse_cpf` in order to make the name compatible with the [js brutils](https://brazilian-utils.com.br/#/utilities)

Pull request description:
feat: add parse_cpf
closes #55 

cc: @antoniamaia 

Patch:
diff --git a/README.md b/README.md
index 62563a8..34ab790 100644
--- a/README.md
+++ b/README.md
@@ -39,7 +39,8 @@ False
 
 ### What if my string has formatting symbols in it?
 ```
->>> cpf.sieve('000.111.222-33')
+>>> from brutils import parse_cpf
+>>> parse_cpf('000.111.222-33')
 '00011122233'
 >>> cnpj.sieve('00.111.222/0001-00')
 '00111222000100'
diff --git a/README_PT_BR.md b/README_PT_BR.md
index 5b852f3..dead564 100644
--- a/README_PT_BR.md
+++ b/README_PT_BR.md
@@ -41,7 +41,8 @@ False
 
 ### E se a minha string estiver formatada com simbolos?
 ```
->>> cpf.sieve('000.111.222-33')
+>>> from brutils import parse_cpf
+>>> parse_cpf('000.111.222-33')
 '00011122233'
 >>> cnpj.sieve('00.111.222/0001-00')
 '00111222000100'
diff --git a/brutils/__init__.py b/brutils/__init__.py
index b6f839a..6df0523 100644
--- a/brutils/__init__.py
+++ b/brutils/__init__.py
@@ -1,2 +1,2 @@
-from brutils.cpf import is_valid as is_valid_cpf, format_cpf
+from brutils.cpf import is_valid as is_valid_cpf, format_cpf, parse as parse_cpf
 from brutils.cnpj import is_valid as is_valid_cnpj, format_cnpj
diff --git a/brutils/cpf.py b/brutils/cpf.py
index 5013f8c..20df337 100644
--- a/brutils/cpf.py
+++ b/brutils/cpf.py
@@ -16,6 +16,17 @@ def sieve(dirty):  # type: (str) -> str
     return "".join(filter(lambda char: char not in ".-", dirty))
 
 
+def parse(dirty):  # type: (str) -> str
+    """
+    Filters out CPF formatting symbols. Symbols that are not used
+    in the CPF formatting are left unfiltered on purpose so that
+    if fails other tests, because their presence indicate that the
+    input was somehow corrupted.
+    """
+
+    return sieve(dirty)
+
+
 def display(cpf):  # type: (str) -> str
     """
     Will format an adequately formatted numbers-only CPF string,


Test patch:
diff --git a/tests/test_cpf.py b/tests/test_cpf.py
index ddb53e7..03ed793 100644
--- a/tests/test_cpf.py
+++ b/tests/test_cpf.py
@@ -17,6 +17,7 @@ from brutils.cpf import (
     generate,
     is_valid,
     format_cpf,
+    parse,
 )
 from unittest import TestCase, main
 
@@ -30,6 +31,14 @@ class CPF(TestCase):
         assert sieve("ab.c1.--.2-309.-1-.6-.*.-!*&#") == "abc1230916*!*&#"
         assert sieve("...---...") == ""
 
+    def test_parse(self):
+        assert parse("00000000000") == "00000000000"
+        assert parse("123.456.789-10") == "12345678910"
+        assert parse("134..2435.-1892.-") == "13424351892"
+        assert parse("abc1230916*!*&#") == "abc1230916*!*&#"
+        assert parse("ab.c1.--.2-309.-1-.6-.*.-!*&#") == "abc1230916*!*&#"
+        assert parse("...---...") == ""
+
     def test_display(self):
         assert display("00000000011") == "000.000.000-11"
         assert display("00000000000") is None