s = "goog.provide( 'goog.date' ); \n goog.require(\"goog.i18n.DateTimeSymbols\" ); \n\n\n mega();\n var a='ffff';";
checkDependencies(s, new String[] { "goog.date" }, new String[] { "goog.i18n.DateTimeSymbols" });
}
private void checkDependencies(String s, String[] provides, String[] requires) {
ClosureDepsParser ccd = new ClosureDepsParser();
DependencyInfo dep = new DependencyInfo(null);
try {
ccd.searchDependencies(new BufferedReader(new StringReader(s)), dep);
assert (checkDependencyInfo(dep, provides, requires));
} catch (IOException e) {
fail(e.getMessage());
}
}