Skip to content

Instantly share code, notes, and snippets.

@stackedsax
Created November 8, 2011 12:18
Show Gist options
  • Save stackedsax/1347618 to your computer and use it in GitHub Desktop.
Save stackedsax/1347618 to your computer and use it in GitHub Desktop.
My grid/node version question
Exception in thread "main" org.openqa.selenium.WebDriverException:
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.6.6', java.version: '1.6.0_26'
Driver info: driver.version: RemoteWebDriver
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:131)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:105)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:409)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:103)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:86)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:94)
at com.yahoo.media.mediaqa.CannCastTest.CannCastTest.main(CannCastTest.java:30)
{
"capabilities":
[
{
"browserName": "firefox",
"platform": "WINDOWS",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox\\firefox.exe",
"seleniumProtocol": "Selenium",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "3.6",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "4.0",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox 4\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "5.0",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox 5\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "6.0",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox 6\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "7.0",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox 7\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "firefox",
"platform": "WINDOWS",
"version": "8.0",
"firefox_binary": "C:\\Program Files\\Mozilla Firefox 8\\firefox.exe",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "chrome",
"platform": "WINDOWS",
"seleniumProtocol": "WebDriver",
"maxInstances": 6
},
{
"browserName": "internet explorer",
"platform": "WINDOWS",
"seleniumProtocol": "WebDriver",
"maxInstances": 1
}
],
"configuration":
{
"maxSession": 6,
"port": 5555,
"register": true,
"registerCycle": 5000
}
}
java -jar selenium-server-standalone.jar -role node -hub http://selgrid2.blah.blah.com:80 -nodeConfig globalmedia_yselenium_rc_config.json 1>>"C:\shared\logon-script\Selenium2RC.log" 2>&1
package com.yahoo.media.mediaqa.selenium2test;
import java.net.MalformedURLException;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.openqa.selenium.remote.RemoteWebDriver;
import java.net.URL;
public class selenium2test {
public static void main(String[] args) {
DesiredCapabilities capability = DesiredCapabilities.firefox();
capability.setVersion("3.6");
try {
WebDriver driver = new RemoteWebDriver(new URL("http://selgrid2.blah.blah.com:80/wd/hub"), capability);
String baseUrl = "http://google.com";
driver.get(baseUrl);
System.out.println(driver.getTitle());
} catch (MalformedURLException e) {
// TODO Auto-generated catch block
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment