More Testcases
This commit is contained in:
parent
30aca3702c
commit
9e96fdad7e
@ -108,6 +108,13 @@ public class OTPTest {
|
||||
OTP testOTP1 = OTP.createNewOTP(OTPType.HOTP, secret, OTPAlgorithm.MD5, 12, 0, 1, true);
|
||||
assertDoesNotThrow(() -> testOTP1.getPin());
|
||||
|
||||
OTP testOTP2 = OTP.createNewOTP(OTPType.TOTP, secret, OTPAlgorithm.MD5, 12, 0, 1, true);
|
||||
for(int i = 0; i < 1000; i++) {
|
||||
assertDoesNotThrow(() -> testOTP2.getPin());
|
||||
testOTP2.incrementCounter();
|
||||
}
|
||||
|
||||
|
||||
//OTP testOTP2 = OTP.createNewOTP(OTPType.HOTP, Base32.encode(hexStr2Bytes(secret)), OTPAlgorithm.MD5, 12, 0, 1, true);
|
||||
//assertDoesNotThrow(() -> testOTP2.getPin());
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user