use of com.google.devtools.build.lib.skyframe.LegacyLoadingPhaseRunner in project bazel by bazelbuild.
the class BuildViewTestCase method update.
protected AnalysisResult update(List<String> targets, List<String> aspects, boolean keepGoing, int loadingPhaseThreads, boolean doAnalysis, EventBus eventBus) throws Exception {
LoadingOptions loadingOptions = Options.getDefaults(LoadingOptions.class);
BuildView.Options viewOptions = Options.getDefaults(BuildView.Options.class);
viewOptions.keepGoing = keepGoing;
viewOptions.loadingPhaseThreads = loadingPhaseThreads;
LoadingPhaseRunner runner = new LegacyLoadingPhaseRunner(getPackageManager(), Collections.unmodifiableSet(ruleClassProvider.getRuleClassMap().keySet()));
LoadingResult loadingResult = runner.execute(reporter, targets, PathFragment.EMPTY_FRAGMENT, loadingOptions, viewOptions.keepGoing, /*determineTests=*/
false, /*callback=*/
null);
if (!doAnalysis) {
// TODO(bazel-team): What's supposed to happen in this case?
return null;
}
return view.update(loadingResult, masterConfig, aspects, viewOptions, AnalysisTestUtil.TOP_LEVEL_ARTIFACT_CONTEXT, reporter, eventBus);
}
Aggregations