Search in sources :

Example 1 with BlazeKotlinSyncPlugin

use of com.google.idea.blaze.kotlin.sync.BlazeKotlinSyncPlugin in project intellij by bazelbuild.

the class KotlinSyncAugmenterTest method initTest.

@Override
protected void initTest(@NotNull Container applicationServices, @NotNull Container projectServices) {
    super.initTest(applicationServices, projectServices);
    ExtensionPointImpl<BlazeSyncPlugin> syncPlugins = registerExtensionPoint(BlazeSyncPlugin.EP_NAME, BlazeSyncPlugin.class);
    syncPlugins.registerExtension(new BlazeJavaSyncPlugin());
    syncPlugins.registerExtension(new BlazeKotlinSyncPlugin());
    BlazeContext context = BlazeContext.create();
    context.addOutputSink(IssueOutput.class, errorCollector);
    ExtensionPointImpl<Kind.Provider> ep = registerExtensionPoint(Kind.Provider.EP_NAME, Kind.Provider.class);
    ep.registerExtension(new JavaBlazeRules());
    ep.registerExtension(new KotlinBlazeRules());
    applicationServices.register(Kind.ApplicationState.class, new Kind.ApplicationState());
    MockExperimentService experimentService = new MockExperimentService();
    applicationServices.register(ExperimentService.class, experimentService);
    augmenters = registerExtensionPoint(BlazeJavaSyncAugmenter.EP_NAME, BlazeJavaSyncAugmenter.class);
    augmenters.registerExtension(new KotlinSyncAugmenter());
}
Also used : JavaBlazeRules(com.google.idea.blaze.java.JavaBlazeRules) MockExperimentService(com.google.idea.common.experiments.MockExperimentService) KotlinBlazeRules(com.google.idea.blaze.kotlin.KotlinBlazeRules) BlazeKotlinSyncPlugin(com.google.idea.blaze.kotlin.sync.BlazeKotlinSyncPlugin) BlazeJavaSyncPlugin(com.google.idea.blaze.java.sync.BlazeJavaSyncPlugin) BlazeContext(com.google.idea.blaze.base.scope.BlazeContext) BlazeJavaSyncAugmenter(com.google.idea.blaze.java.sync.BlazeJavaSyncAugmenter) Kind(com.google.idea.blaze.base.model.primitives.Kind) BlazeSyncPlugin(com.google.idea.blaze.base.sync.BlazeSyncPlugin)

Aggregations

Kind (com.google.idea.blaze.base.model.primitives.Kind)1 BlazeContext (com.google.idea.blaze.base.scope.BlazeContext)1 BlazeSyncPlugin (com.google.idea.blaze.base.sync.BlazeSyncPlugin)1 JavaBlazeRules (com.google.idea.blaze.java.JavaBlazeRules)1 BlazeJavaSyncAugmenter (com.google.idea.blaze.java.sync.BlazeJavaSyncAugmenter)1 BlazeJavaSyncPlugin (com.google.idea.blaze.java.sync.BlazeJavaSyncPlugin)1 KotlinBlazeRules (com.google.idea.blaze.kotlin.KotlinBlazeRules)1 BlazeKotlinSyncPlugin (com.google.idea.blaze.kotlin.sync.BlazeKotlinSyncPlugin)1 MockExperimentService (com.google.idea.common.experiments.MockExperimentService)1