diff --git a/packages/schematics/angular/application/files/module-files/src/app/app.spec.ts.template b/packages/schematics/angular/application/files/module-files/src/app/app.spec.ts.template index e3f5c5fff092..43a982f1f3b1 100644 --- a/packages/schematics/angular/application/files/module-files/src/app/app.spec.ts.template +++ b/packages/schematics/angular/application/files/module-files/src/app/app.spec.ts.template @@ -22,12 +22,6 @@ describe('App', () => { expect(app).toBeTruthy(); }); - it(`should have as title '<%= name %>'`, () => { - const fixture = TestBed.createComponent(App); - const app = fixture.componentInstance; - expect(app.title).toEqual('<%= name %>'); - }); - it('should render title', () => { const fixture = TestBed.createComponent(App); fixture.detectChanges(); diff --git a/packages/schematics/angular/application/files/module-files/src/app/app.ts.template b/packages/schematics/angular/application/files/module-files/src/app/app.ts.template index ca94fc7bb99a..a7de7291cb3c 100644 --- a/packages/schematics/angular/application/files/module-files/src/app/app.ts.template +++ b/packages/schematics/angular/application/files/module-files/src/app/app.ts.template @@ -15,5 +15,5 @@ import { Component } from '@angular/core'; styleUrl: './app.<%= style %>'<% } %> }) export class App { - title = '<%= name %>'; + protected title = '<%= name %>'; } diff --git a/packages/schematics/angular/application/files/standalone-files/src/app/app.spec.ts.template b/packages/schematics/angular/application/files/standalone-files/src/app/app.spec.ts.template index eb529a1df3c7..808723635d96 100644 --- a/packages/schematics/angular/application/files/standalone-files/src/app/app.spec.ts.template +++ b/packages/schematics/angular/application/files/standalone-files/src/app/app.spec.ts.template @@ -16,12 +16,6 @@ describe('App', () => { expect(app).toBeTruthy(); }); - it(`should have the '<%= name %>' title`, () => { - const fixture = TestBed.createComponent(App); - const app = fixture.componentInstance; - expect(app.title).toEqual('<%= name %>'); - }); - it('should render title', () => { const fixture = TestBed.createComponent(App); fixture.detectChanges(); diff --git a/packages/schematics/angular/application/files/standalone-files/src/app/app.ts.template b/packages/schematics/angular/application/files/standalone-files/src/app/app.ts.template index 74ea464e5d04..ec40bb8c0c07 100644 --- a/packages/schematics/angular/application/files/standalone-files/src/app/app.ts.template +++ b/packages/schematics/angular/application/files/standalone-files/src/app/app.ts.template @@ -16,5 +16,5 @@ import { RouterOutlet } from '@angular/router';<% } %> styleUrl: './app.<%= style %>'<% } %> }) export class App { - title = '<%= name %>'; + protected title = '<%= name %>'; }