mercredi 14 septembre 2016

Protractor by repeater Iterating over object properties

My ng-repeat looks something like this
<div ng-repeat="(idx, field) in content">

And in protractor I want to get the row where the field.type === 'some value' which I'm not being able to do. I don't know if there's a direct way to do this but my approach at this time is getting all rows with

element.all(by.repeater('(idx, field) in content'));
which gives me 10 elements.

And then was trying to get the types using
element.all(by.repeater('(idx, field) in content').column('field.type'));
which gives me 0 elements.

In Protractor documentation by repeater there are some examples but none use this separation on the repeater.

What am I doing wrong or what could be a different approach to filter these rows.

Aucun commentaire:

Enregistrer un commentaire