File tree Expand file tree Collapse file tree
packages/schematics/angular/module Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -165,28 +165,6 @@ describe('Module Schematic', () => {
165165 ) ;
166166 } ) ;
167167
168- it ( 'should not inherit the component `type` from the workspace defaults' , async ( ) => {
169- // The CLI applies the `schematics` defaults of `angular.json` to nested schematics as well.
170- // Emulate it with a fresh runner so that other tests are not affected.
171- const runner = new SchematicTestRunner (
172- '@schematics/angular' ,
173- require . resolve ( '../collection.json' ) ,
174- ) ;
175- runner [ '_engineHost' ] . registerOptionsTransform (
176- ( schematic : { name : string } , options : Record < string , unknown > ) =>
177- schematic . name === 'component' && options [ 'type' ] === undefined
178- ? { ...options , type : 'component' }
179- : options ,
180- ) ;
181-
182- const tree = await runner . runSchematic ( 'module' , options , appTree ) ;
183-
184- expect ( tree . exists ( '/projects/bar/src/app/foo/foo.ts' ) ) . toBe ( true ) ;
185- expect ( tree . exists ( '/projects/bar/src/app/foo/foo.component.ts' ) ) . toBe ( false ) ;
186- const content = tree . readContent ( '/projects/bar/src/app/foo/foo-routing-module.ts' ) ;
187- expect ( content ) . toContain ( `import { Foo } from './foo';` ) ;
188- } ) ;
189-
190168 it ( 'should generate a lazy loaded module with embedded route declarations' , async ( ) => {
191169 appTree . overwrite (
192170 '/projects/bar/src/app/app-module.ts' ,
You can’t perform that action at this time.
0 commit comments