Files
2024-02-15 17:01:50 +00:00

17 lines
483 B
Python

import pytest
from sentry.auth.providers.github.views import _get_name_from_email
expected_data = [
("[email protected]", "John Smith"),
("[email protected]", "John"),
("[email protected]", "Xyz-234=3523"),
("[email protected]", "Xyz 1111"),
("[email protected]", "John"),
]
@pytest.mark.parametrize("email,expected_name", expected_data)
def test_get_name_from_email(email, expected_name):
assert _get_name_from_email(email) == expected_name