use of oidc.model.UserConsent in project OpenConext-oidcng by OpenConext.
the class ResourceCleanerTest method userConsent.
private UserConsent userConsent() {
UserConsent userConsent = new UserConsent(new User("sub", "unspecifiedNameId", "http://mockidp", "clientId", Collections.emptyMap(), Collections.emptyList()), Arrays.asList("openid", "profile"), new OpenIDClient());
Date lastAccessed = Date.from(new Date().toInstant().minus(365 * 10, ChronoUnit.DAYS).atZone(ZoneId.systemDefault()).toInstant());
ReflectionTestUtils.setField(userConsent, "lastAccessed", lastAccessed);
return userConsent;
}
Aggregations