javascript - Recommended way to locate parent element in Protractor -
according newly published style guide, using by.xpath()
locators considered bad practice. i'm trying follow suggestion, stuck on getting parent element.
currently using ..
xpath expression element's parent:
this.dashboard = element(by.linktext("dashboard")).element(by.xpath(".."));
how can locate element's parent using other built protractor/webdriverjs locators?
alecxe, while dig style guide, , agree xpath avoided, there's exception proves rule. think 1 of cases :)
Comments
Post a Comment