I'm writing some e2e tests with protractor. My application is an Angular Material 2 application. In my test I want to select an option of a md-select by value. When I inspect the open md-select I see the md-option items. The values of the options are in an attribute ng-reflect-value.
Let's say I have an option with the value "optionA". How can I select a certain option by this value?
I tried this:
element(by.name('myselect')).click();
$$('.mat-option').then((options) => {
...
});
and inside then I see the correct number of options, but how can I select the option which has the value "opetionA" ?