I figured it out. i need to use using to focus the scope. example
using('div[filter="search.username"]').input("filter").enter("foo"); using('div[filter="search.ami"]').input("filter").enter("bar")
Question
in our program we have a directive that occurs multiple times with an input field. Our code looks something like this
<li>
<label>AMI</label>
<div class="searchbox" searchbox="" filter="search.ami">
<form ng-submit="doFilter()" class="ng-pristine ng-valid">
<input class="span12 ng-pristine ng-valid" type="text" placeholder="" ng-model="filter">
</form>
</div>
</li>
<li>
<label>Username</label>
<div class="searchbox" searchbox="" filter="search.username">
<form ng-submit="doFilter()" class="ng-pristine ng-valid">
<input class="span12 ng-pristine ng-valid" type="text" placeholder="" ng-model="filter">
</form>
</div>
</li>
now using the angular e2e test it says use the "input(name).enter(value)" to input, where the name is the ng-model. If i do this and say "input('filter').enter('foo')" both input fields will get inputted. I can't figure out how to just input one field at a time. How would you do so.
Solution
I figured it out. i need to use using to focus the scope. example
using('div[filter="search.username"]').input("filter").enter("foo"); using('div[filter="search.ami"]').input("filter").enter("bar")