MCPcopy Create free account
hub / github.com/angular/components / getChildLoader

Function getChildLoader

src/cdk/testing/harness-environment.ts:313–319  ·  view source on GitHub ↗

* Searches for an element with the given selector under the evironment's root element, * and returns a `HarnessLoader` rooted at the matching element. If multiple elements match the * selector, the first is used. If no elements match, an error is thrown. * @param selector The selector for t

(selector: string)

Source from the content-addressed store, hash-verified

311 * @throws If a matching element can't be found.
312 */
313 async getChildLoader(selector: string): Promise<HarnessLoader> {
314 return this.createEnvironment(
315 await _assertResultFound(this.getAllRawElements(selector), [
316 _getDescriptionForHarnessLoaderQuery(selector),
317 ]),
318 );
319 }
320
321 /**
322 * Searches for all elements with the given selector under the environment's root element,

Callers

nothing calls this directly

Calls 4

_assertResultFoundFunction · 0.85
createEnvironmentMethod · 0.45
getAllRawElementsMethod · 0.45

Tested by

no test coverage detected