TestabilityRegistry

class

npm Package @angular/core
Module import { TestabilityRegistry } from '@angular/core';
Source core/src/testability/testability.ts

Overview

class TestabilityRegistry {
  constructor()
  registerApplication(token: any, testability: Testability)
  unregisterApplication(token: any)
  unregisterAllApplications()
  getTestability(elem: any): Testability | null
  getAllTestabilities(): Testability[]
  getAllRootElements(): any[]
  findTestabilityInTree(elem: Node, findInAncestors: boolean = true): Testability | null
}

Description

A global registry of Testability instances for specific elements.

Constructor

constructor()

Members

registerApplication(token: any, testability: Testability)

Registers an application with a testability hook so that it can be tracked

unregisterApplication(token: any)

Unregisters an application.

unregisterAllApplications()

Unregisters all applications

getTestability(elem: any): Testability | null

Get a testability hook associated with the application

getAllTestabilities(): Testability[]

Get all registered testabilities

getAllRootElements(): any[]

Get all registered applications(root elements)

findTestabilityInTree(elem: Node, findInAncestors: boolean = true): Testability | null

Find testability of a node in the Tree

Annotations

@Injectable()

© 2010–2018 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://v5.angular.io/api/core/TestabilityRegistry