Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: third_party/pkg/angular/test/bootstrap_spec.dart

Issue 124053002: Adding Angular and dependent packages for testing (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 library bootstrap_spec;
2
3 import '_specs.dart';
4
5 main() => describe('bootstrap', () {
6 BodyElement body = window.document.querySelector('body');
7
8 it('should default to whole page', () {
9 body.innerHtml = '<div>{{"works"}}</div>';
10 ngBootstrap();
11 expect(body.innerHtml).toEqual('<div>works</div>');
12 });
13
14 it('should compile starting at ng-app node', () {
15 body.setInnerHtml(
16 '<div>{{ignor me}}<div ng-app ng-bind="\'works\'"></div></div>',
17 treeSanitizer: new NullTreeSanitizer());
18 ngBootstrap();
19 expect(body.text).toEqual('{{ignor me}}works');
20 });
21
22 it('should compile starting at ng-app node', () {
23 body.setInnerHtml(
24 '<div>{{ignor me}}<div ng-bind="\'works\'"></div></div>',
25 treeSanitizer: new NullTreeSanitizer());
26 ngBootstrap(element:body.querySelector('div[ng-bind]'));
27 expect(body.text).toEqual('{{ignor me}}works');
28 });
29 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698