Add name validation
This commit is contained in:
@ -19,7 +19,7 @@ def dummy_account() -> FromAccount:
|
||||
postal_code="7523 05",
|
||||
city="Assen",
|
||||
country="Netherlands",
|
||||
name="Astrid Janneke Willems",
|
||||
ebanking_name="Astrid Janneke Willems",
|
||||
phone_number="+31 06 34579996",
|
||||
email="astrid.willems@upcmail.nl",
|
||||
)
|
||||
|
@ -20,4 +20,9 @@ def test_invalid_phone_number() -> None:
|
||||
dummy = dummy_account()
|
||||
with pytest.raises(ValidationError):
|
||||
dummy.phone_number = "This should be invalid"
|
||||
dummy.phone_number = "+41 32 333 33 33"
|
||||
dummy.phone_number = "+41 32 333 33 33"
|
||||
|
||||
def test_check_account_name_ebanking_name() -> None:
|
||||
dummy = dummy_account()
|
||||
with pytest.raises(ValidationError):
|
||||
dummy.ebanking_name = "This is not the same as the account name"
|
Reference in New Issue
Block a user