Minor doc updates. Added a test case.

This commit is contained in:
Les Hazlewood 2015-03-14 18:37:47 -07:00
parent dd856ea844
commit 6631b0b8c4
3 changed files with 24 additions and 1 deletions

View File

@ -26,6 +26,13 @@ public class ExpiredJwtException extends ClaimJwtException {
super(header, claims, message);
}
/**
* @param header jwt header
* @param claims jwt claims (body)
* @param message exception message
* @param cause cause
* @since 0.5
*/
public ExpiredJwtException(Header header, Claims claims, String message, Throwable cause) {
super(header, claims, message, cause);
}

View File

@ -26,7 +26,13 @@ public class PrematureJwtException extends ClaimJwtException {
super(header, claims, message);
}
@SuppressWarnings("UnusedDeclaration")
/**
* @param header jwt header
* @param claims jwt claims (body)
* @param message exception message
* @param cause cause
* @since 0.5
*/
public PrematureJwtException(Header header, Claims claims, String message, Throwable cause) {
super(header, claims, message, cause);
}

View File

@ -76,4 +76,14 @@ class SignatureAlgorithmTest {
}
}
@Test
void testIsJdkStandard() {
for(SignatureAlgorithm alg : SignatureAlgorithm.values()) {
if (alg.name().startsWith("ES") || alg.name().startsWith("PS") || alg == SignatureAlgorithm.NONE) {
assertFalse alg.isJdkStandard()
} else {
assertTrue alg.isJdkStandard()
}
}
}
}