webdriver is not able to click on a hyperlink in firefox

后端 未结 6 2099
不思量自难忘°
不思量自难忘° 2021-01-16 23:01
package testproject;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.firefox.         


        
6条回答
  •  不知归路
    2021-01-16 23:36

    Please try below. It should work

    List elements = driver.findElement(By.LinkText("Gmail"))
    elements.get(0).click().
    

提交回复
热议问题