def remote_driver
@browser = Watir::Browser.new(:remote,
:url => "http:://.....:4444/wd/hub", :http_client => client,
:desired_capabilities => capabilities
)
end def capabilities
Selenium::WebDriver::Remote::Capabilities.send(
@driver_name,
:javascript_enabled => true,
:css_selectors_enabled => true,
:takes_screenshot => true
)
end def client
client = Selenium::WebDriver::Remote::Http::Default.new
client.timeout = 360
client
end{
"host": null,
"port": <%= node[:selenium][:server][:port] %>,
"newSessionWaitTimeout": -1,
"servlets" : [],
"prioritizer": null,
"capabilityMatcher": "org.openqa.grid.internal.utils.DefaultCapabilityMatcher",
"throwOnCapabilityNotPresent": true,
"nodePolling": <%= node[:selenium][:server][:node_polling] %>,
"cleanUpCycle": <%= node[:selenium][:server][:cleanup_cycle] %>,
"timeout": <%= node[:selenium][:server][:timeout] %>,
"browserTimeout": 0,
"maxSession": <%= node[:selenium][:server][:max_session] %>
}{"capabilities": [{"browserName": "firefox","maxInstances": 5,"seleniumProtocol": "WebDriver"}, {"browserName": "chrome","maxInstances": 5,"seleniumProtocol": "WebDriver"}, {"browserName": "phantomjs","maxInstances": 5,"seleniumProtocol": "WebDriver"}],"configuration": {"proxy": "org.openqa.grid.selenium.proxy.DefaultRemoteProxy","maxSession": <%= node[:selenium][:node][:max_session] %>,"port": <%= node[:selenium][:node][:port] %>,"host": "<%= node[:fqdn] %>","register": true,"registerCycle": <%= node[:selenium][:node][:register_cycle] %>,"hubPort": <%= node[:selenium][:server][:port] %>}}
{"browserName": "firefox","maxInstances": 5,
"applicationName" : "MyApp","version": "FF important","seleniumProtocol": "WebDriver"},
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/0b327e18-302e-45c4-8295-d5f2de572514%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.