Package com.google.gwt.dev.javac.testing.impl

Examples of com.google.gwt.dev.javac.testing.impl.StaticJavaResource


        getEnumSerializationSignature("FOO, BAR { @Override public String toString() { return \"QUUX\"; } }, BAZ"));
  }

  protected String getEnumSerializationSignature(String constants) throws NotFoundException {
    TypeOracle to = TypeOracleTestingUtils.buildStandardTypeOracleWith(TreeLogger.NULL,
        new StaticJavaResource("TestEnum", "public enum TestEnum { " + constants + " }"));
    MockContext context = new MockContext(to);
    JClassType enumType = to.getType("TestEnum");
    return SerializationUtils.getSerializationSignature(context, enumType);
  }
View Full Code Here


    sb.append("class Temp {\n");
    sb.append("}");

    ApiContainer apiCheckLoop =
        new ApiContainer("ApiClassTest", new HashSet<Resource>(Arrays
            .asList(new StaticJavaResource[] {new StaticJavaResource("java.lang.Object", sb
                .toString())})), new HashSet<String>(), logger);
    ApiPackage javaLangPackage = apiCheckLoop.getApiPackage("java.lang");
    assertNotNull(javaLangPackage);
    assertNotNull(javaLangPackage.getApiClass("java.lang.Object"));
    assertEquals(2, javaLangPackage.getApiClassNames().size());
View Full Code Here

    AbstractTreeLogger logger = new PrintWriterTreeLogger();
    logger.setMaxDetail(TreeLogger.ERROR);

    Set<Resource> set1 = new HashSet<Resource>();
    for (Map.Entry<String, String> entry : existingTypesToSourcesMap.entrySet()) {
      set1.add(new StaticJavaResource(entry.getKey(), entry.getValue()));
    }
    Set<String> emptyList = Collections.emptySet();
    Set<Resource> set2 = new HashSet<Resource>();
    for (String type : existingTypesToSourcesMap.keySet()) {
      set2.add(new StaticJavaResource(type, newTypesToSourcesMap.get(type)));
    }

    ApiContainer existingApi = new ApiContainer("existingApi", set1, emptyList, logger);
    ApiContainer newApi = new ApiContainer("newApi", set2, emptyList, logger);
    return ApiCompatibilityChecker.getApiDiff(newApi, existingApi, emptyList);
View Full Code Here

  // These cups are slightly different from the cups in ApiContainerTest
  private static final boolean DEBUG = false;

  private static StaticJavaResource[] getScuArray() {
    return new StaticJavaResource[] {
        new StaticJavaResource("test.apicontainer.ApiClass", getSourceForApiClass()),
        new StaticJavaResource("test.apicontainer.NonApiClass", getSourceForNonApiClass()),
        new StaticJavaResource("test.nonapipackage.TestClass", getSourceForTestClass()),
        new StaticJavaResource("java.lang.Object", getSourceForObject()),
        new StaticJavaResource("java.lang.Throwable", getSourceForThrowable()),
        new StaticJavaResource("test.apicontainer.OneMoreApiClass", getSourceForOneMoreApiClass()),
        new StaticJavaResource("java.lang.RuntimeException", getSourceForRuntimeException()),};
  }
View Full Code Here

    }
  }

  public static StaticJavaResource[] getScuArray() {
    return new StaticJavaResource[] {
        new StaticJavaResource("test.apicontainer.ApiClass", getSourceForApiClass()),
        new StaticJavaResource("test.apicontainer.NonApiClass", getSourceForNonApiClass()),
        new StaticJavaResource("test.nonapipackage.TestClass", getSourceForTestClass()),
        new StaticJavaResource("java.lang.Object", getSourceForObject()),
        new StaticJavaResource("test.apicontainer.OneMoreApiClass", getSourceForOneMoreApiClass()),
        new StaticJavaResource("java.newpackage.Test", getSourceForTest()),};
  }
View Full Code Here

TOP

Related Classes of com.google.gwt.dev.javac.testing.impl.StaticJavaResource

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.