I am using [EmailAddress]
attribute to validate my email input textfield as the following
[EmailAddress]
public string NewBusNotificationEmail { get; set; }
For my testing, I tried the following
test
- validation failed
test@
- validation failed
test@test.
- validation failed
However, when I tried test@test
- validation passed
I also noticed that it does not test for madeup suffix like tets@test.test
- validation passed. For test@test
, it should be validation fail. Why not? how to fix this?