@Test
public void testSetAuthenticationTokenFactory() {

    AuthenticationTokenFactory factory = new AuthenticationTokenFactory() {
        @Override
        public AuthenticationToken getAuthenticationToken(SubjectConnectionReference ref) throws Exception {
            return null;
        }
    };
    filter.setAuthenticationTokenFactory(factory);
    assertSame(factory, filter.getAuthenticationTokenFactory());
}