mherrmann / helium

Lighter web automation for Python

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Click Method always selects first instance

deathknightracer opened this issue · comments

Hi:
I absolutely love using Helium (100x better than using pure Selenium).
Context: Webpage has hyperlink text like:
Business Enterprise Plus
Business Enterprise
Problem: I try to use the click method to click the 2nd line, but it keeps clicking first line.
Question: Is there any chance to update the click method to specify which instance to click?
Let me know if there is another way I should try to achieve this click on the 2nd link.
I defer to your judgment and brilliance.
Thanks,

Thank you for the kind words! I'm happy you like Helium.

I think you should be able to use:

click(Link('Business Enterprise', below='Business Enterprise Plus'))

If that doesn't work, try Text(...) instead of Link(...).