Skip to content
This repository has been archived by the owner on Feb 22, 2018. It is now read-only.

fix(TestBed): TestBed toNodeList and whitespace #1262

Closed
ofagbemi opened this issue Jul 24, 2014 · 0 comments
Closed

fix(TestBed): TestBed toNodeList and whitespace #1262

ofagbemi opened this issue Jul 24, 2014 · 0 comments

Comments

@ofagbemi
Copy link
Contributor

I was using the TestBed class and found that the rootElement member wasn't being set properly. After some searching, I found that the problem was with the toNodeList function and the string I was passing to the TestBed's compile function:

String html => '''
  <component>
    <some-directive></some-directive>
  </component>
''';

The node list returned by toNodeList looked something like this

[        
, component,          ]

It looks like toNodeList doesn't play well with whitespace. I got around it by just trimming the string first, but I don't know if that could introduce any other issues down the line.

@ofagbemi ofagbemi changed the title TestBed toNodeList and whitespace fix(TestBed): TestBed toNodeList and whitespace Jul 24, 2014
jbdeboer pushed a commit to jbdeboer/angular.dart that referenced this issue Aug 29, 2014
Add whitespace handling to the TestBed’s compile function.

Closes dart-archive#1262. Previously, strings passed with leading or
trailing whitespace would be compiled incorrectly. Now,
valid HTML with arbitrary whitespace in and surrounding it
can be compiled properly.

Closes dart-archive#1346
jbdeboer pushed a commit to jbdeboer/angular.dart that referenced this issue Sep 11, 2014
Add whitespace handling to the TestBed’s compile function.

Closes dart-archive#1262. Previously, strings passed with leading or
trailing whitespace would be compiled incorrectly. Now,
valid HTML with arbitrary whitespace in and surrounding it
can be compiled properly.

Closes dart-archive#1346
jbdeboer pushed a commit to jbdeboer/angular.dart that referenced this issue Sep 11, 2014
Add whitespace handling to the TestBed’s compile function.

Closes dart-archive#1262. Previously, strings passed with leading or
trailing whitespace would be compiled incorrectly. Now,
valid HTML with arbitrary whitespace in and surrounding it
can be compiled properly.

Closes dart-archive#1346
vsavkin pushed a commit that referenced this issue Sep 14, 2014
Add whitespace handling to the TestBed’s compile function.

Closes #1262. Previously, strings passed with leading or
trailing whitespace would be compiled incorrectly. Now,
valid HTML with arbitrary whitespace in and surrounding it
can be compiled properly.

Closes #1346

Closes #1445
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
1 participant