Hi I can't figure out how to get an element by CSS and matching with text. I know it can be done with Xpath but I'd rather use CSS.
<div class="button-face"> <div class="button-face-caption"> Text I want to find 1</div> </div> <div class="button-face"> <div class="button-face-caption"> Text I want to find 2</div> </div>
So in by CSS would be something like...
driver.find_element_by_css('div.button-face-caption')
But how can add the text matching to that? i tried with contains
and innerText
and none seem to work.
<div class="button-face">
?