Examples of Versioner


Examples of org.apache.shindig.gadgets.uri.JsUriManager.Versioner

  public void makeJsUriWithVersionerNoVersionOnIgnoreCache() {
    ContainerConfig config = mockConfig("http://www.js.org", "/gadgets/js");
    List<String> extern = Lists.newArrayList("feature");
    JsUri ctx = mockGadgetContext(true, false, extern)// no cache
    String version = "verstring";
    Versioner versioner = this.mockVersioner(ctx, version, version);
    TestDefaultJsUriManager manager = makeManager(config, versioner);
    Uri jsUri = manager.makeExternJsUri(ctx);
    assertFalse(manager.hadError());
    assertEquals("http", jsUri.getScheme());
    assertEquals("www.js.org", jsUri.getAuthority());
View Full Code Here

Examples of org.apache.shindig.gadgets.uri.JsUriManager.Versioner

    ContainerConfig config = mockConfig("http://" + targetHost, "/gadgets/js");
    List<String> extern = Lists.newArrayList("feature", "another");
    String version = "verstring";
    String badVersion = version + "-a";
    JsUri ctx = mockGadgetContext(false, false, extern);
    Versioner versioner = mockVersioner(ctx, version, badVersion);
    TestDefaultJsUriManager manager = makeManager(config, versioner);
    Uri testUri = Uri.parse("http://target-host.org/gadgets/js/" + addJsLibs(extern) +
        JS_SUFFIX + '?' + Param.CONTAINER.getKey() + '=' + CONTAINER + '&' +
        Param.VERSION.getKey() + '=' + badVersion);
    JsUri jsUri = manager.processExternJsUri(testUri);
View Full Code Here

Examples of org.apache.shindig.gadgets.uri.JsUriManager.Versioner

    String targetHost = "target-host.org";
    ContainerConfig config = mockConfig("http://" + targetHost, "/gadgets/js");
    List<String> extern = Lists.newArrayList("feature", "another");
    String version = "verstring";
    JsUri ctx = mockGadgetContext(false, false, extern);
    Versioner versioner = mockVersioner(ctx, version, version);
    TestDefaultJsUriManager manager = makeManager(config, versioner);
    Uri testUri = Uri.parse("http://target-host.org/gadgets/js/" + addJsLibs(extern) +
        JS_SUFFIX + '?' + Param.CONTAINER.getKey() + '=' + CONTAINER);
    JsUri jsUri = manager.processExternJsUri(testUri);
    assertFalse(manager.hadError());
View Full Code Here

Examples of org.apache.shindig.gadgets.uri.JsUriManager.Versioner

    String targetHost = "target-host.org";
    ContainerConfig config = mockConfig("http://" + targetHost, "/gadgets/js");
    List<String> extern = Lists.newArrayList("feature", "another");
    String version = "verstring";
    JsUri ctx = mockGadgetContext(false, false, extern);
    Versioner versioner = mockVersioner(ctx, version, version);
    TestDefaultJsUriManager manager = makeManager(config, versioner);
    Uri testUri = Uri.parse("http://target-host.org/gadgets/js/" + addJsLibs(extern) +
        JS_SUFFIX + '?' + Param.CONTAINER.getKey() + '=' + CONTAINER + '&' +
        Param.VERSION.getKey() + '=' + version);
    JsUri jsUri = manager.processExternJsUri(testUri);
View Full Code Here

Examples of org.apache.shindig.gadgets.uri.JsUriManager.Versioner

    // Make...
    ContainerConfig config = mockConfig("http://www.js.org", "/gadgets/js");
    List<String> extern = Lists.newArrayList("feature1", "feature2", "feature3");
    JsUri ctx = mockGadgetContext(false, false, extern);
    String version = "verstring";
    Versioner versioner = mockVersioner(ctx, version, version);
    TestDefaultJsUriManager manager = makeManager(config, versioner);
    Uri jsUri = manager.makeExternJsUri(ctx);
    assertFalse(manager.hadError());
    assertEquals("http", jsUri.getScheme());
    assertEquals("www.js.org", jsUri.getAuthority());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.