2016-06-23 12:47:54 -04: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 20:50:03 -04:00
|
|
|
import {DebugElement} from '@angular/core';
|
2016-06-08 19:38:52 -04:00
|
|
|
import {By} from '@angular/platform-browser';
|
2015-12-03 18:49:09 -05:00
|
|
|
|
2017-03-24 12:57:05 -04:00
|
|
|
let debugElement: DebugElement = undefined !;
|
2015-12-03 18:49:09 -05:00
|
|
|
class MyDirective {}
|
|
|
|
|
|
|
|
// #docregion by_all
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.all());
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_css
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.css('[attribute]'));
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_directive
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.directive(MyDirective));
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|