PreAuthenticatedAuthenticationProvider extends TimeMeasuringAuthenticationProvider<AuthenticationResult> { @Override public AuthorizationContextType getType(final RequestContext requestContext) { return DittoAuthorizationContextType.PRE_AUTHENTICATED_HTTP; } private  PreAuthenticatedAuthenticationProvider(); static PreAuthenticatedAuthenticationProvider getInstance(); @Override boolean isApplicable(final RequestContext requestContext); @Override AuthorizationContextType getType(final RequestContext requestContext);  }
@Test public void getType() { final AuthorizationContextType type = underTest.getType(mockRequestContext(DUMMY_AUTH_HEADER, DUMMY_AUTH_QUERY)); AssertionsForClassTypes.assertThat(type).isEqualTo(DittoAuthorizationContextType.PRE_AUTHENTICATED_HTTP); }