diff --git a/packages/compiler-cli/test/ngc_spec.ts b/packages/compiler-cli/test/ngc_spec.ts index ca4d822aa0..239c188ee6 100644 --- a/packages/compiler-cli/test/ngc_spec.ts +++ b/packages/compiler-cli/test/ngc_spec.ts @@ -2364,36 +2364,6 @@ describe('ngc transformer command-line', () => { 'Module.ngInjectorDef = i0.defineInjector({ factory: function Module_Factory() { return new Module(); }, providers: ɵ1, imports: [ɵ2, ɵ3] });'); }); - it('strips decorator in ivy mode', () => { - writeConfig(`{ - "extends": "./tsconfig-base.json", - "files": ["service.ts"], - "angularCompilerOptions": { - "enableIvy": true - } - }`); - write('service.ts', ` - import {Injectable, Self} from '@angular/core'; - - @Injectable() - export class ServiceA {} - - @Injectable() - @Self() - export class ServiceB {} - `); - - const exitCode = main(['-p', path.join(basePath, 'tsconfig.json')], errorSpy); - expect(exitCode).toEqual(0); - - const modulePath = path.resolve(outDir, 'service.js'); - const moduleSource = fs.readFileSync(modulePath, 'utf8'); - expect(moduleSource).not.toMatch(/ServiceA\.decorators =/); - expect(moduleSource).toMatch(/ServiceB\.decorators =/); - expect(moduleSource).toMatch(/type: Self/); - expect(moduleSource).not.toMatch(/type: Injectable/); - }); - it('rewrites Injector to INJECTOR in Ivy factory functions ', () => { writeConfig(`{ "extends": "./tsconfig-base.json",