@Test
public void captchImage() throws IOException
{
File file = new File("extension.xpi");
FirefoxProfile firefoxProfile = new FirefoxProfile();
firefoxProfile.addExtension(file);
WebDriver driver = new FirefoxDriver(firefoxProfile);
driver.get("http://njdg.ecourts.gov.in/njdg_public/index.php");
我想與插件一起打開Firefox瀏覽器i attached image please go through that如何使用taht我加入瀏覽器的所有插件一起打開瀏覽器
什麼是'extension.xpi'? –
代碼似乎是正確的,提供的路徑xpi文件是正確的(是嗎?)。你正在使用哪種Firefox,並且是你的擴展簽名?最新的FF不喜歡未簽名的擴展。我建議在瀏覽器打開時暫停測試並檢查擴展是否存在,以及是否已啓用(可能已安裝但未啓用) –
@KirilS。我的擴展已簽署 –