Created
December 11, 2021 22:10
-
-
Save felipebaltazar/d4a510c5e9e17202d24ad79b171585f7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MyViewModelTests | |
{ | |
private readonly MyViewModel _myViewModel = new MyViewModel(); | |
[Theory] | |
[InlineData("111.111.111-11", true)] | |
[InlineData("111111.111-11", false)] | |
[InlineData("111.111111-11", false)] | |
[InlineData("111.111.11111", false)] | |
[InlineData("11111111111", false)] | |
[InlineData("qioweoi1nadslk", false)] | |
public void IsValidCPF_ShouldValidateStringMask(string input, bool expectedValue) | |
{ | |
var result = _myViewModel.IsValidCPF(input); | |
Assert.Equal(expectedValue, result); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment