public void ShouldReturnEmptyStringForInvalidEmail() { var testData = UserTestData.Setup(false); var provider = new SrirachaMembershipProvider(testData.Repository.Object); string userName = provider.GetUserNameByEmail(Guid.NewGuid().ToString()); Assert.AreEqual(string.Empty, userName); }
public void ShouldReturnUserNameByEmail() { var testData = UserTestData.Setup(true); var provider = new SrirachaMembershipProvider(testData.Repository.Object); string userName = provider.GetUserNameByEmail(testData.SrirachaUser.EmailAddress); Assert.AreEqual(testData.SrirachaUser.UserName, userName); }