File tree 2 files changed +12
-1
lines changed
packages/schematics/angular/application
2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -418,7 +418,7 @@ export default function (options: ApplicationOptions): Rule {
418
418
] ) , MergeStrategy . Overwrite ) ,
419
419
addTsConfigProjectReferences ( [
420
420
join ( appDir , 'tsconfig.app.json' ) ,
421
- join ( appDir , 'tsconfig.spec.json' ) ,
421
+ ... options . minimal ? [ ] : [ join ( appDir , 'tsconfig.spec.json' ) ] ,
422
422
] ) ,
423
423
options . minimal ? noop ( ) : schematic ( 'e2e' , e2eOptions ) ,
424
424
options . skipPackageJson ? noop ( ) : addDependenciesToPackageJson ( options ) ,
Original file line number Diff line number Diff line change @@ -91,6 +91,17 @@ describe('Application Schematic', () => {
91
91
] ) ;
92
92
} ) ;
93
93
94
+ it ( 'minimal=true should add correct reference in tsconfig' , async ( ) => {
95
+ const options = { ...defaultOptions , minimal : true } ;
96
+ const tree = await schematicRunner . runSchematicAsync ( 'application' , options , workspaceTree )
97
+ . toPromise ( ) ;
98
+
99
+ const { references } = readJsonFile ( tree , '/tsconfig.json' ) ;
100
+ expect ( references ) . toEqual ( [
101
+ { path : './projects/foo/tsconfig.app.json' } ,
102
+ ] ) ;
103
+ } ) ;
104
+
94
105
it ( 'should set the prefix to app if none is set' , async ( ) => {
95
106
const options = { ...defaultOptions } ;
96
107
You can’t perform that action at this time.
0 commit comments