Dear Patron,
I am trying to find button With text "Connect" using
connect_buttons = firefox.find_elements_by_link_text ('Connect')
#But firefox is not able to find button.
<button aria-label="Connect with ABC" class="search-result__actions--primary button-secondary-medium m5" data-ember-action="" data-ember-action-1510="1510">Connect</button>
<button aria-label="Connect with DEF" class="search-result__actions--primary button-secondary-medium m5" data-ember-action="" data-ember-action-1467="1467">Invite Sent !</button>
Even i have tried using following mode too
firefox.find_elements_by_xpath("//*[contains(text(), 'Connect')]")
# Not accurate results
firefox.find_elements_by_css_selector('.search-result__actions--primary.button-secondary-medium.m5');
# return all button with same css even which doesn't have text "Connect".
Please suggest.
What I have tried:
connect_buttons = firefox.find_elements_by_link_text ('Connect');
connect_buttons = firefox.find_elements_by_xpath("//*[contains(text(), 'Connect')]")
connect_buttons = firefox.find_elements_by_css_selector('.search-result__actions--primary.button-secondary-medium.m5');