标签: css protractor
How can we find the CSS path of web elements using the property 'contains text'? In xpath its quite simple. Help me to get the same using CSS
答案 0 :(得分:1)
鉴于你用“量角器”标记了问题,我认为你试图用量角器选择一个元素。假设是这种情况,你可以这样做:
element(by.cssContainingText('h1', foo));