In protractor I am using Jasmine to write test cases. I want to find the link with link text. What is the code in protractor to find element by link text?
I am giving you the code for finding the element by link text in protractor test cases.
Here is code example:
var myElement = element(by.linkText('Login')); myElement.click();
Above code finds the link with 'Login" text and then clicks on it.
Hope this will help you.