Package org.springframework.mock.web

Examples of org.springframework.mock.web.PassThroughFilterChain


        assertTrue(TransactionSynchronizationManager.hasResource(factory2));
        filter.doFilter(servletRequest, servletResponse, filterChain);
      }
    };

    FilterChain filterChain3 = new PassThroughFilterChain(filter2, filterChain2);

    assertFalse(TransactionSynchronizationManager.hasResource(factory));
    assertFalse(TransactionSynchronizationManager.hasResource(factory2));
    filter2.doFilter(request, response, filterChain3);
    assertFalse(TransactionSynchronizationManager.hasResource(factory));
View Full Code Here


        MultipartHttpServletRequest request = (MultipartHttpServletRequest) servletRequest;
        files.addAll(request.getFileMap().values());
      }
    };

    FilterChain filterChain2 = new PassThroughFilterChain(filter, filterChain);

    MockHttpServletRequest originalRequest = new MockHttpServletRequest();
    MockHttpServletResponse response = new MockHttpServletResponse();
    originalRequest.setMethod("POST");
    originalRequest.setContentType("multipart/form-data");
View Full Code Here

        assertTrue(TransactionSynchronizationManager.hasResource(sf2));
        filter.doFilter(servletRequest, servletResponse, filterChain);
      }
    };

    FilterChain filterChain3 = new PassThroughFilterChain(filter2, filterChain2);

    assertFalse(TransactionSynchronizationManager.hasResource(sf));
    assertFalse(TransactionSynchronizationManager.hasResource(sf2));
    filter2.doFilter(request, response, filterChain3);
    assertFalse(TransactionSynchronizationManager.hasResource(sf));
View Full Code Here

        filter.doFilter(servletRequest, servletResponse, filterChain);
      }
    };

    FilterChain filterChain3 = new PassThroughFilterChain(filter2, filterChain2);

    filter2.doFilter(request, response, filterChain3);
    assertNotNull(request.getAttribute("invoked"));

    sfControl.verify();
View Full Code Here

        assertTrue(TransactionSynchronizationManager.hasResource(pmf2));
        filter.doFilter(servletRequest, servletResponse, filterChain);
      }
    };

    FilterChain filterChain3 = new PassThroughFilterChain(filter2, filterChain2);

    assertFalse(TransactionSynchronizationManager.hasResource(pmf));
    assertFalse(TransactionSynchronizationManager.hasResource(pmf2));
    filter2.doFilter(request, response, filterChain3);
    assertFalse(TransactionSynchronizationManager.hasResource(pmf));
View Full Code Here

    ReflectionTestUtils.setField(filter, "pluginManager", pluginManager);
   
    filter.init();
    filter.onPluginEnabled(null);
    filter.doFilter(new MockHttpServletRequest(), new MockHttpServletResponse(),
        new PassThroughFilterChain(new FreemarkerServlet()));
    filter.onPluginDisabled(null);
  }
View Full Code Here

    @Before
    public void setUp() throws Exception {
        UrlRewriteFilter filter =
                createUrlFilter(SiteConfig.REWRITE_FILTER_NAME,
                        SiteConfig.REWRITE_FILTER_CONF_PATH);
        filterChain = new PassThroughFilterChain(filter, new MockFilterChain());
    }
View Full Code Here

TOP

Related Classes of org.springframework.mock.web.PassThroughFilterChain

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.