### Question:
ConfigurableJwtTokenValidator implements JwtTokenValidator { @Override public void assertValidToken(String tokenString) throws JwtTokenValidatorException { verify(issuer, tokenString, new JWSVerificationKeySelector<>( JWSAlgorithm.RS256, remoteJWKSet ) ); } ConfigurableJwtTokenValidator(
        String issuer,
        List<String> optionalClaims,
        RemoteJWKSet<SecurityContext> remoteJWKSet
    ); @Override void assertValidToken(String tokenString);  }### Answer:
@Test public void assertValidToken() throws JwtTokenValidatorException { JwtTokenValidator validator = tokenValidator(ISSUER, List.of("aud", "sub")); JWT token = createSignedJWT(ISSUER, null, null); validator.assertValidToken(token.serialize()); }
@Test public void testAssertUnexpectedIssuer() throws JwtTokenValidatorException { String otherIssuer = "https: JwtTokenValidator validator = tokenValidator(otherIssuer, Collections.emptyList()); JWT token = createSignedJWT(ISSUER, null, null); assertThrows(JwtTokenValidatorException.class, () -> validator.assertValidToken(token.serialize())); }