public void PutOtp_Should_StoreOtpsAndReturnNotNullToken_When_NotNullOtpVerificationTokenPassed() { //Arrange var otpStorage = new InMemoryOtpStorage(); var token = otpStorage.PutOtp("12345"); Assert.IsNotNull(token); }
public void PutOtpAndGetOtp_Should_StoreAndReturnCorrectOtp_When_NotNullOtpPassed() { //Arrange var otpStorage = new InMemoryOtpStorage(); var otp = "12345"; var token = otpStorage.PutOtp(otp); var otpUnderTest = otpStorage.GetOtp(token); Assert.AreEqual(otpUnderTest, otp); }
public void PutOtp_Should_ThrowArgumentException_When_EmptyOtpPassed() { //Arrange var otpStorage = new InMemoryOtpStorage(); var token = otpStorage.PutOtp(string.Empty); }
public void PutOtp_Should_ThrowArgumentException_When_WhiteSpaceOtpPassed() { //Arrange var otpStorage = new InMemoryOtpStorage(); var token = otpStorage.PutOtp(" "); }
public void GetOtp_Should_ThrowArgumentException_When_NullOtpVerificationTokenPassed() { //Arrange var otpStorage = new InMemoryOtpStorage(); var token = otpStorage.GetOtp(null); }