File tree Expand file tree Collapse file tree 3 files changed +14
-3
lines changed
tools/public_api_guard/core/testing Expand file tree Collapse file tree 3 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -275,7 +275,7 @@ export const ContentChild: ContentChildDecorator = makePropDecorator(
275
275
[ 'selector' , undefined ] , {
276
276
first : true ,
277
277
isViewQuery : false ,
278
- descendants : false ,
278
+ descendants : true ,
279
279
read : undefined ,
280
280
}
281
281
] ,
Original file line number Diff line number Diff line change @@ -250,6 +250,17 @@ export function main() {
250
250
expect ( comp . textDirChild . text ) . toEqual ( 'ca' ) ;
251
251
} ) ;
252
252
253
+ it ( 'should contain the first descendant content child' , ( ) => {
254
+ const template = '<needs-content-child-read>' +
255
+ '<div dir><div #q text="ca"></div></div>' +
256
+ '</needs-content-child-read>' ;
257
+ const view = createTestCmpAndDetectChanges ( MyComp0 , template ) ;
258
+
259
+ const comp : NeedsContentChildWithRead =
260
+ view . debugElement . children [ 0 ] . injector . get ( NeedsContentChildWithRead ) ;
261
+ expect ( comp . textDirChild . text ) . toEqual ( 'ca' ) ;
262
+ } ) ;
263
+
253
264
it ( 'should contain the first view child' , ( ) => {
254
265
const template = '<needs-view-child-read></needs-view-child-read>' ;
255
266
const view = createTestCmpAndDetectChanges ( MyComp0 , template ) ;
Original file line number Diff line number Diff line change @@ -20,10 +20,10 @@ export declare class ComponentFixture<T> {
20
20
}
21
21
22
22
/** @experimental */
23
- export declare var ComponentFixtureAutoDetect : OpaqueToken ;
23
+ export declare const ComponentFixtureAutoDetect : OpaqueToken ;
24
24
25
25
/** @experimental */
26
- export declare var ComponentFixtureNoNgZone : OpaqueToken ;
26
+ export declare const ComponentFixtureNoNgZone : OpaqueToken ;
27
27
28
28
/** @experimental */
29
29
export declare function discardPeriodicTasks ( ) : void ;
You can’t perform that action at this time.
0 commit comments