File tree 2 files changed +3
-10
lines changed
packages/angular_devkit/core/src/workspace/json
2 files changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -190,11 +190,7 @@ function parseProject(
190
190
191
191
const projectNodeValue = getNodeValue ( projectNode ) ;
192
192
if ( ! ( 'root' in projectNodeValue ) ) {
193
- // TODO(alan-agius4): change this to error in v15.
194
- context . warn (
195
- `Project "${ projectName } " is missing a required property "root". This will become an error in the next major version.` ,
196
- projectNodeValue ,
197
- ) ;
193
+ throw new Error ( `Project "${ projectName } " is missing a required property "root".` ) ;
198
194
}
199
195
200
196
for ( const [ name , value ] of Object . entries < JsonValue > ( projectNodeValue ) ) {
Original file line number Diff line number Diff line change @@ -148,11 +148,8 @@ describe('readJsonWorkpace Parsing', () => {
148
148
}
149
149
` ) ;
150
150
151
- const consoleWarnSpy = spyOn ( console , 'warn' ) . and . callFake ( ( ) => undefined ) ;
152
- await expectAsync ( readJsonWorkspace ( '' , host ) ) ;
153
-
154
- expect ( consoleWarnSpy ) . toHaveBeenCalledWith (
155
- `Project "foo" is missing a required property "root". This will become an error in the next major version.` ,
151
+ await expectAsync ( readJsonWorkspace ( '' , host ) ) . toBeRejectedWithError (
152
+ / P r o j e c t " f o o " i s m i s s i n g a r e q u i r e d p r o p e r t y " r o o t " / ,
156
153
) ;
157
154
} ) ;
158
155
} ) ;
You can’t perform that action at this time.
0 commit comments