3
是否有可能使用硒c#在Saucelab中测试浏览器扩展。如果是的话,如何以及在哪里放置最新的扩展包saucelab VM,以便硒启动扩展浏览器。在Saucelabs中使用硒c#进行浏览器扩展测试
是否有可能使用硒c#在Saucelab中测试浏览器扩展。如果是的话,如何以及在哪里放置最新的扩展包saucelab VM,以便硒启动扩展浏览器。在Saucelabs中使用硒c#进行浏览器扩展测试
对于Firefox和Chrome,可以通过提供功能或配置文件。例如在Firefox的情况下:
File file = new File(“firebug-1.8.1.xpi”); FirefoxProfile firefoxProfile = new FirefoxProfile(); firefoxProfile.addExtension(file); firefoxProfile.setPreference(“extensions.firebug.currentVersion”,“1.8.1”); //避开启动画面
WebDriver driver = new FirefoxDriver(firefoxProfile);