当我使用Selenium网格时,没有在节点桌面中启动执行
当我使用Selenium网格时,没有在节点桌面中开始执行。在这里,我尝试在NodeDesktop中启动Firefox浏览器。我如何解决这个问题?您的回答将不胜感激。提前谢谢当我使用Selenium网格时,没有在节点桌面中启动执行,selenium,selenium-grid,Selenium,Selenium Grid,当我使用Selenium网格时,没有在节点桌面中开始执行。在这里,我尝试在NodeDesktop中启动Firefox浏览器。我如何解决这个问题?您的回答将不胜感激。提前谢谢 **Below is my code** public class GridExample { WebDriver driver; String baseUrl,nodeUrl; @BeforeTest public void setup()
**Below is my code**
public class GridExample {
WebDriver driver;
String baseUrl,nodeUrl;
@BeforeTest
public void setup() throws MalformedURLException{
baseUrl="https://www.google.com/ncr";
nodeUrl="http://**.0.0.*:5566/wd/hub";
System.setProperty("webdriver.gecko.driver","D://krishna//geckodriver-v0.11.1-win32//geckodriver.exe");
DesiredCapabilities capabilities=DesiredCapabilities.firefox();
capabilities.setBrowserName("firefox");
capabilities.setPlatform(Platform.VISTA);
driver=new RemoteWebDriver(new URL(nodeUrl),capabilities);
}
@Test
public void sampleTest() throws InterruptedException{
driver.get(baseUrl);
Thread.sleep(10000); //slow down for demo purposes
WebElement element = driver.findElement(By.name("q"));
element.sendKeys("webdriver");
element.submit();
Thread.sleep(5000);
}
@AfterTest
public void teardown(){
driver.close();
}
}
**Below is my output stacktrace**
2017年6月9日下午5:35:55 org.openqa.selenium.remote.ProtocolHandshake
createSession信息:正在尝试双方言会话,假设Postel
在远程端log4j上,法律是正确的:警告:不能使用附加器
为记录器(org.apache.http.client.protocol.RequestAddCookies)找到。
log4j:警告请正确初始化log4j系统。log4j:请参阅
更多信息
配置失败:@BeforeTest安装程序
org.openqa.selenium.remote.UnreachableBrowserException:无法访问
开始新的会话。可能的原因是远程服务器的地址无效
服务器或浏览器启动失败。生成信息:版本:“未知”,
版本:“1969d75”,时间:“2016-10-18 09:43:45-0700”系统信息:
主机:“SYSTEM26-PC”,ip:“10.0.0.14”,os.name:“Windows 7”,os.arch:
'amd64',os.version:'6.1',java.version:'1.8.0_111'
SKIPPED CONFIGURATION: @AfterTest tear down SKIPPED: sampleTest org.openqa.selenium.remote.UnreachableBrowserException: Could not
开始新的会话。可能的原因是远程服务器的地址无效
服务器或浏览器启动失败。生成信息:版本:“未知”,
版本:“1969d75”,时间:“2016-10-18 09:43:45-0700”系统信息:
主机:“SYSTEM26-PC”,ip:“10.0.0.14”,os.name:“Windows 7”,os.arch:
'amd64',os.version:'6.1',java.version:'1.8.0_111'
SKIPPED CONFIGURATION: @AfterTest tear down SKIPPED: sampleTest org.openqa.selenium.remote.UnreachableBrowserException: Could not
===============================================
默认测试
测试运行:1,失败:0,跳过:1
配置失败:1,跳过:1
============================================================默认套件总测试运行次数:1,失败次数:0,跳过次数:1配置失败次数:1,跳过次数:
1.
任何人请帮助我…这里几乎没有什么信息可以开始调试。请包括浏览器和seleniumSelenium版本3.0和Firefox版本53.0.3的版本号是完整的stacktrace吗?嗨,Mahadevan,我在上面添加了完整的stacktrace