test(ng-repeat): enables nested ng-repeat test.
It was failing previously because we were using nested <li> incorrectly.
This commit is contained in:
parent
1d0de3ea54
commit
8a8a4b2ae7
|
@ -173,25 +173,24 @@ export function main() {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
/*
|
|
||||||
TODO(rado): enable after compiler is fixed.
|
|
||||||
it('should repeat over nested arrays', (done) => {
|
it('should repeat over nested arrays', (done) => {
|
||||||
compileWithTemplate(
|
compileWithTemplate(
|
||||||
'<ul><li template="ng-repeat #item in items">{{item.toString()}}' +
|
'<div><div template="ng-repeat #item in items">' +
|
||||||
'<li template="ng-repeat #subitem in item">' +
|
'<div template="ng-repeat #subitem in item">' +
|
||||||
'{{subitem}};' +
|
'{{subitem}};' +
|
||||||
'</li>X</li></ul>'
|
'</div>|</div></div>'
|
||||||
).then((pv) => {
|
).then((pv) => {
|
||||||
createView(pv);
|
createView(pv);
|
||||||
component.items = [['a', 'b'], ['c','d']];
|
component.items = [['a', 'b'], ['c','d']];
|
||||||
cd.detectChanges();
|
cd.detectChanges();
|
||||||
cd.detectChanges();
|
cd.detectChanges();
|
||||||
cd.detectChanges();
|
cd.detectChanges();
|
||||||
expect(DOM.getText(view.nodes[0])).toEqual('');
|
expect(DOM.getText(view.nodes[0])).toEqual('a;b;|c;d;|');
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
/*
|
||||||
TODO(rado): enable after compiler is fixed.
|
TODO(rado): enable after compiler is fixed.
|
||||||
it('should display indices correctly', (done) => {
|
it('should display indices correctly', (done) => {
|
||||||
var INDEX_TEMPLATE = '<div><copy-me template="ng-repeat #item in items index #i">{{index.toString()}};</copy-me></div>';
|
var INDEX_TEMPLATE = '<div><copy-me template="ng-repeat #item in items index #i">{{index.toString()}};</copy-me></div>';
|
||||||
|
|
Loading…
Reference in New Issue