#vulnerable code 
                              @Test
  public void testNoProcessorWroManagerFactory() throws IOException {
    final WroManagerFactory factory = new ServletContextAwareWroManagerFactory();
    manager = factory.getInstance();
    manager.setModelFactory(getValidModelFactory());
    final HttpServletRequest request = Mockito.mock(HttpServletRequest.class);
    final OutputStream os = System.out;
    final HttpServletResponse response = Context.get().getResponse();

    final InputStream actualStream = WroTestUtils.convertToInputStream(os);
    Mockito.when(response.getOutputStream()).thenReturn(new DelegatingServletOutputStream(os));
    Mockito.when(request.getRequestURI()).thenReturn("/app/g1.css");
    manager.process(request, response);
    WroTestUtils.compare(getInputStream("classpath:ro/isdc/wro/manager/noProcessorsResult.css"), actualStream);
  } 
                            #location 11 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                              @Test
  public void testNoProcessorWroManagerFactory() throws IOException {
    final WroManagerFactory factory = new ServletContextAwareWroManagerFactory();
    manager = factory.getInstance();
    manager.setModelFactory(getValidModelFactory());
    final HttpServletRequest request = Mockito.mock(HttpServletRequest.class);
    final HttpServletResponse response = Context.get().getResponse();

    final ByteArrayOutputStream out = new ByteArrayOutputStream();
    Mockito.when(response.getOutputStream()).thenReturn(new DelegatingServletOutputStream(out));
    Mockito.when(request.getRequestURI()).thenReturn("/app/g1.css");
    manager.process(request, response);
    //compare written bytes to output stream with the content from specified css.
    WroTestUtils.compare(getInputStream("classpath:ro/isdc/wro/manager/noProcessorsResult.css"), new ByteArrayInputStream(out.toByteArray()));
  }