According to the documentation, to get a single attribute by name you can use getAttribute()
:
var myElement = element(by.id('myId'));
expect(myElement.getAttribute('myAttr')).toEqual('myValue');
But how can I get all of the attributes that an element has?
There is no information about it at the Protractor API documentation page.
Aucun commentaire:
Enregistrer un commentaire