Package org.apache.shindig.gadgets.rewrite.ContentRewriterFeature

Examples of org.apache.shindig.gadgets.rewrite.ContentRewriterFeature.Config


  @Test
  public void testImportsAndBackgroundUrlsInStyleTagDefaultContainer() throws Exception {
    // TODO: IMPORTANT!  This test needs to not rely on the packaged shindig config, but rather
    //       mock the config with expected values, so that tests do not fail when people set
    //       alternative defaults.
    Config config = injector.getInstance(ContentRewriterFeature.DefaultConfig.class);
    EasyMock.replay();
    if (config.isRewriteEnabled())
      testImportsAndBackgroundUrlsInStyleTag(ORIGINAL, EXPECTED, ContainerConfig.DEFAULT_CONTAINER, config);
    else
      testImportsAndBackgroundUrlsInStyleTag(ORIGINAL, NOREWRITE, ContainerConfig.DEFAULT_CONTAINER, config);
  }
View Full Code Here


  @Test
  public void testImportsAndBackgroundUrlsInStyleTagMockContainer() throws Exception {
    // TODO: IMPORTANT!  This test needs to not rely on the packaged shindig config, but rather
    //       mock the config with expected values, so that tests do not fail when people set
    //       alternative defaults.
    Config config = injector.getInstance(ContentRewriterFeature.DefaultConfig.class);
    EasyMock.replay();

    if (config.isRewriteEnabled()) {
      testImportsAndBackgroundUrlsInStyleTag(ORIGINAL, EXPECTED.replace(
          "localhost:8080/gadgets/proxy?container=default", "www.mock.com/gadgets/proxy?container=mock"),
          MOCK_CONTAINER, config);
    } else {
      testImportsAndBackgroundUrlsInStyleTag(ORIGINAL, NOREWRITE, ContainerConfig.DEFAULT_CONTAINER, config);
View Full Code Here

TOP

Related Classes of org.apache.shindig.gadgets.rewrite.ContentRewriterFeature.Config

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.