@Test public void shouldReturnANullHandlerWhenThereIsNoEncodingInitParameter() throws Exception { when(context.getInitParameter(ENCODING)).thenReturn(null); EncodingHandlerFactory handlerFactory = new EncodingHandlerFactory(context); assertThat(handlerFactory.getInstance(), is(instanceOf(NullEncodingHandler.class))); }
public EncodingHandler getInstance() { return handler; }
EncodingHandlerFactory implements ComponentFactory<EncodingHandler> { public EncodingHandler getInstance() { return handler; } }
EncodingHandlerFactory implements ComponentFactory<EncodingHandler> { public EncodingHandler getInstance() { return handler; } EncodingHandlerFactory(ServletContext context); }
EncodingHandlerFactory implements ComponentFactory<EncodingHandler> { public EncodingHandler getInstance() { return handler; } EncodingHandlerFactory(ServletContext context); EncodingHandler getInstance(); }
EncodingHandlerFactory implements ComponentFactory<EncodingHandler> { public EncodingHandler getInstance() { return handler; } EncodingHandlerFactory(ServletContext context); EncodingHandler getInstance();  }