2016-06-23 09:47:54 -07:00
|
|
|
/**
|
|
|
|
* @license
|
|
|
|
* Copyright Google Inc. All Rights Reserved.
|
|
|
|
*
|
|
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
|
|
* found in the LICENSE file at https://angular.io/license
|
|
|
|
*/
|
|
|
|
|
2016-04-28 17:50:03 -07:00
|
|
|
import {DebugElement} from '@angular/core';
|
2016-06-08 16:38:52 -07:00
|
|
|
import {By} from '@angular/platform-browser';
|
2015-12-03 15:49:09 -08:00
|
|
|
|
2017-03-24 09:57:05 -07:00
|
|
|
let debugElement: DebugElement = undefined !;
|
2015-12-03 15:49:09 -08:00
|
|
|
class MyDirective {}
|
|
|
|
|
|
|
|
// #docregion by_all
|
2016-01-13 21:35:21 -08:00
|
|
|
debugElement.query(By.all());
|
2015-12-03 15:49:09 -08:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_css
|
2016-01-13 21:35:21 -08:00
|
|
|
debugElement.query(By.css('[attribute]'));
|
2015-12-03 15:49:09 -08:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_directive
|
2016-01-13 21:35:21 -08:00
|
|
|
debugElement.query(By.directive(MyDirective));
|
2015-12-03 15:49:09 -08:00
|
|
|
// #enddocregion
|