export async function bootstrap()

in src/app.module.ts [23:53]


export async function bootstrap(context: vscode.ExtensionContext) {
  // Define the application's dependencies.  This is done at runtime to allow for dynamically created providers such as extension context.
  // NestJS also supports dynamic modules, but they currently have compatbility issues with VS Code's runtime environment.
  // TODO(IDE-984): Invesigate why the NestConstainer.addModule method causes Node to report dependence on "extensionRuntime" experimental API.
  @Module({
    providers: [
      contextProviderFactory(context),
      outputChannelProvider,
      BuildServerManager,
      BazelBSPBuildClient,
      TestResolver,
      TestRunner,
      TestCaseStore,
      RunTrackerFactory,
      ConnectionDetailsParser,
      BazelBSPInstaller,
      TestItemFactory,
      CoverageTracker,
      LanguageToolManager,
      SyncHintDecorationsManager,
      testControllerProvider,
    ],
  })
  class AppModule {}

  const app = await NestFactory.createApplicationContext(AppModule)

  context.subscriptions.push({
    dispose: async () => await app.close(),
  })
}