String benchmark = "hello";
String module = "com.google.gwt.sample.hello.Hello";
File work = Utility.makeTemporaryDirectory(null, benchmark + "work");
try {
CompilerOptionsImpl options = new CompilerOptionsImpl();
options.addModuleName(module);
options.setWarDir(new File(work, "war"));
options.setExtraDir(new File(work, "extra"));
options.setOptimizationLevel(optimizeLevel);
PrintWriterTreeLogger logger = new PrintWriterTreeLogger();
logger.setMaxDetail(TreeLogger.ERROR);
new com.google.gwt.dev.Compiler(options).run(logger);
// Change parentDir for cached/pre-built reports
String parentDir = options.getExtraDir() + "/" + benchmark;
for (Map<String, SimpleSymbolData> symbolDataBySymbolName :
loadSymbolMaps(new File(parentDir + "/symbolMaps/"))) {
assertTrue(!symbolDataBySymbolName.isEmpty());
assertNotNull(symbolDataBySymbolName.get(JSE_METHOD));
assertTrue(symbolDataBySymbolName.get(JSE_METHOD).isMethod());