Tech Mahindra Interview Question

Using Selenium how would you perform a Right Click?

Interview Answer

Anonymous

Apr 17, 2025

I said, "there is an option in selenium that you wrap driver that that gives you the new methods such as right click.". In the real world I would just look it up in the selenium documentation. CORRECT ANSWER: new Actions(driver).ContextClick(element).Perform();