public void Validate_GivenValidPhoneNumber_ShouldNotHaveError()
            {
                EditContactInfoViewModelValidator subject = _fixture.Create <EditContactInfoViewModelValidator>();

                subject.ShouldNotHaveValidationErrorFor(x => x.PhoneNumber, "1234567890");
                subject.ShouldNotHaveValidationErrorFor(x => x.PhoneNumber, "(123) 456-7890");
                subject.ShouldNotHaveValidationErrorFor(x => x.PhoneNumber, "123-456-7890");
            }
            public void Validate_GivenAvailableEmailAddress_ShouldNotHaveError()
            {
                _fakeUserManager.Setup(x => x.GetUserIdForEmailAddress("*****@*****.**")).Returns(null as int?);
                EditContactInfoViewModelValidator subject = _fixture.Create <EditContactInfoViewModelValidator>();

                subject.ShouldNotHaveValidationErrorFor(x => x.EmailAddress, "*****@*****.**");
            }
            public void Validate_GivenCurrentEmailAddress_ShouldNotHaveError()
            {
                _fakeUserManager.Setup(x => x.GetUserIdForEmailAddress("*****@*****.**")).Returns(123);
                EditContactInfoViewModel model = new EditContactInfoViewModel
                {
                    UserId       = 123,
                    EmailAddress = "*****@*****.**"
                };
                EditContactInfoViewModelValidator subject = _fixture.Create <EditContactInfoViewModelValidator>();

                subject.ShouldNotHaveValidationErrorFor(x => x.EmailAddress, model);
            }
            public void Validate_GivenPopulatedFirstName_ShouldNotHaveError()
            {
                EditContactInfoViewModelValidator subject = _fixture.Create <EditContactInfoViewModelValidator>();

                subject.ShouldNotHaveValidationErrorFor(x => x.FirstName, "first name");
            }