@@ -0,0 +1,1864 @@
+from ..anonymize import obfuscate_address, obfuscate_email, obfuscate_string%0A%0A%0Adef test_obfuscate_email():%0A    # given%0A    email = %22abc@gmail.com%22%0A%0A    # when%0A    result = obfuscate_email(email)%0A%0A    # then%0A    assert result == %22a...@example.com%22%0A%0A%0Adef test_obfuscate_email_example_email():%0A    # given%0A    email = %22abc@example.com%22%0A%0A    # when%0A    result = obfuscate_email(email)%0A%0A    # then%0A    assert result == %22abc@example.com%22%0A%0A%0Adef test_obfuscate_email_no_at_in_email():%0A    # given%0A    email = %22abcgmail.com%22%0A%0A    # when%0A    result = obfuscate_email(email)%0A%0A    # then%0A    assert result == %22a...........%22%0A%0A%0Adef test_obfuscate_string():%0A    # given%0A    value = %22AbcDef%22%0A%0A    # when%0A    result = obfuscate_string(value)%0A%0A    # then%0A    assert result == %22A.....%22%0A%0A%0Adef test_obfuscate_string_empty_string():%0A    # given%0A    value = %22%22%0A%0A    # when%0A    result = obfuscate_string(value)%0A%0A    # then%0A    assert result == value%0A%0A%0Adef test_obfuscate_string_phone_string():%0A    # given%0A    value = %22+40123123123%22%0A%0A    # when%0A    result = obfuscate_string(value, phone=True)%0A%0A    # then%0A    assert result == %22+40.........%22%0A%0A%0Adef test_obfuscate_address(address):%0A    # given%0A    first_name = address.first_name%0A    last_name = address.last_name%0A    company_name = address.company_name%0A    street_address_1 = address.street_address_1%0A    phone = str(address.phone)%0A%0A    # when%0A    result = obfuscate_address(address)%0A%0A    # then%0A    assert result.first_name == first_name%5B0%5D + %22.%22 * (len(first_name) - 1)%0A    assert result.last_name == last_name%5B0%5D + %22.%22 * (len(last_name) - 1)%0A    assert result.company_name == company_name%5B0%5D + %22.%22 * (len(company_name) - 1)%0A    assert result.street_address_1 == street_address_1%5B0%5D + %22.%22 * (%0A        len(street_address_1) - 1%0A    )%0A    assert result.street_address_2 == %22%22%0A    assert result.phone == phone%5B:3%5D + %22.%22 * (len(phone) - 3)%0A

Add tests for anpnymize methods