From a73d2a76882b0fa98082966a31bafe31ae306c41 Mon Sep 17 00:00:00 2001 From: Keen Yee Liau Date: Thu, 14 May 2020 16:05:20 -0700 Subject: [PATCH] test(language-service): Remove unused code in test project (#37122) This commit removes the `bootstrap()` function in the test project since its presence has no effect on the behavior of language service. Also removes the explicit cast when instantiating `CounterDirectiveContext`, and let type inference takes care of that. PR Close #37122 --- packages/language-service/test/project/app/main.ts | 4 ---- packages/language-service/test/project/app/parsing-cases.ts | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/packages/language-service/test/project/app/main.ts b/packages/language-service/test/project/app/main.ts index d79be4001f..e026037b87 100644 --- a/packages/language-service/test/project/app/main.ts +++ b/packages/language-service/test/project/app/main.ts @@ -27,7 +27,3 @@ import * as ParsingCases from './parsing-cases'; }) export class AppModule { } - -declare function bootstrap(v: any): void; - -bootstrap(AppComponent); diff --git a/packages/language-service/test/project/app/parsing-cases.ts b/packages/language-service/test/project/app/parsing-cases.ts index 65bbbf90c6..434dde91d5 100644 --- a/packages/language-service/test/project/app/parsing-cases.ts +++ b/packages/language-service/test/project/app/parsing-cases.ts @@ -49,7 +49,7 @@ export class CounterDirective implements OnChanges { ngOnChanges(_changes: SimpleChanges) { this.container.clear(); for (let i = 0; i < this.counter; ++i) { - this.container.createEmbeddedView(this.template, new CounterDirectiveContext(i + 1)); + this.container.createEmbeddedView(this.template, new CounterDirectiveContext(i + 1)); } } }