1 Answer

0 votes
by
By using getAttribute method by passing argument as value. getAttribute() method returns a promise which contains String

Syntax:

element(by.xpath("text box xpath").getAttribute("value")).then(function(textValue){

console.log(textValue)

});

element(by.xpath("text box xpath").getAttribute("value")).then(function(textValue){

console.log(textValue)

});

Related questions

0 votes
asked Apr 5, 2021 in Protractor by Robindeniel
0 votes
asked Apr 5, 2021 in Protractor by Robindeniel
...