Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
M3DZIK committed May 5, 2024
1 parent 3245701 commit c8f09fb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/test/java/dev/medzik/otp/OTPParametersTests.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public void testBuildOTPAuthURL() throws URISyntaxException {

assertEquals(decoded.getType(), OTPType.HOTP);
assertEquals(decoded.getSecret().getEncoded(), "JBSWY3DPEHPK3PXP");
assertEquals(decoded.getIssuer().getValue(), "Example");
assertEquals(decoded.getIssuer(), "Example");
assertEquals(decoded.getAlgorithm(), OTPParameters.Algorithm.SHA256);
assertEquals(decoded.getDigits(), OTPParameters.Digits.SEVEN);
assertNull(decoded.getPeriod());
Expand Down
6 changes: 3 additions & 3 deletions src/test/java/dev/medzik/otp/OTPParserTests.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public void testParseTOTPFirst() throws Exception {

assertEquals(params.getType(), OTPType.TOTP);
assertEquals(params.getSecret().getEncoded(), "JBSWY3DPEHPK3PXP");
assertEquals(params.getIssuer().getValue(), "Example");
assertEquals(params.getIssuer(), "Example");
assertEquals(params.getAlgorithm(), OTPParameters.Algorithm.SHA1);
assertEquals(params.getDigits(), OTPParameters.Digits.SIX);
assertEquals(params.getPeriod(), OTPParameters.Period.THIRTY);
Expand All @@ -29,7 +29,7 @@ public void testParseTOTPSecond() throws Exception {

assertEquals(params.getType(), OTPType.TOTP);
assertEquals(params.getSecret().getEncoded(), "JBSWY3DPEHPK3PXP");
assertEquals(params.getIssuer().getValue(), "Example");
assertEquals(params.getIssuer(), "Example");
assertEquals(params.getAlgorithm(), OTPParameters.Algorithm.SHA512);
assertEquals(params.getDigits(), OTPParameters.Digits.EIGHT);
assertEquals(params.getPeriod(), OTPParameters.Period.FIFTEEN);
Expand All @@ -44,7 +44,7 @@ public void testParseHOTPFirst() throws Exception {

assertEquals(params.getType(), OTPType.HOTP);
assertEquals(params.getSecret().getEncoded(), "JBSWY3DPEHPK3PXP");
assertEquals(params.getIssuer().getValue(), "Example");
assertEquals(params.getIssuer(), "Example");
assertEquals(params.getAlgorithm(), OTPParameters.Algorithm.SHA256);
assertEquals(params.getDigits(), OTPParameters.Digits.SEVEN);
assertNull(params.getPeriod());
Expand Down

0 comments on commit c8f09fb

Please sign in to comment.