ByteArrayOutputStream baos = new ByteArrayOutputStream();
PrintStream ps = new PrintStream(baos);
JavacTool tool = JavacTool.create();
int rc = tool.run(null, null, ps, args);
String out = showOutput(baos.toString());
checkCompilationOK(rc);
checkOutput(out, expectWarnings);