@Test
public void testMissiongCookie() throws IOException, ServletException {

    Mockito.when(request.getCookies()).thenReturn( new Cookie[] { new Cookie("bogus", "") } );
    
    FilterChain test = new FilterChain() {
        @Override
        public void doFilter(ServletRequest request, ServletResponse response) throws IOException, ServletException {
            try {
                HttpCookieCallback callback = new HttpCookieCallback("cookie");
                JaasHttpCallbackHandlerFilter.CALLBACK_HANDLER.handle(callback, null);
                
                assertThat(callback.getCookie()).isEmpty();
            } catch (UnsupportedCallbackException e) {
                fail("Failure on handle() call", e);
            }
        }
    };
    
    filter.doFilter(request, response, test);
}