Skip to content

Commit 02cfa9a

Browse files
committed
rb - w3c updates
1 parent 9eb5e30 commit 02cfa9a

File tree

5 files changed

+15
-14
lines changed

5 files changed

+15
-14
lines changed

Rakefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,8 @@ task :test_rb => [
260260
"//rb:remote-chrome-test",
261261
"//rb:remote-firefox-test",
262262
"//rb:remote-phantomjs-test",
263-
("//rb:marionette-test" if ENV['MARIONETTE_PATH']),
264-
("//rb:remote-marionette-test" if ENV['MARIONETTE_PATH']),
263+
"//rb:marionette-test",
264+
"//rb:remote-marionette-test",
265265
("//rb:safari-test" if mac?),
266266
("//rb:remote-safari-test" if mac?),
267267
("//rb:ie-test" if windows?),

rb/lib/selenium/webdriver/remote/w3c_capabilities.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ def json_create(data)
117117
caps.takes_element_screenshot = data.delete("takesElementScreenshot") if data.key? "takesElementScreenshot"
118118
caps.page_load_strategy = data.delete("pageLoadStrategy") if data.key? "pageloadStrategy"
119119
proxy = data.delete('proxy')
120-
caps.proxy = Proxy.json_create(proxy) unless proxy.empty?
120+
caps.proxy = Proxy.json_create(proxy) unless proxy.nil? || proxy.empty?
121121

122122
# Remote Server Specific
123123
caps[:remote_session_id] = data.delete('webdriver.remote.sessionid')

rb/spec/integration/selenium/webdriver/firefox/marionette_spec.rb

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,12 @@ def restart_remote_server(path = nil)
112112
compliant_on :browser => :marionette do
113113
# This passes in isolation, but can not run in suite due to combination of
114114
# https://bugzilla.mozilla.org/show_bug.cgi?id=1228107 & https://github.com/SeleniumHQ/selenium/issues/1150
115-
not_compliant_on :driver => :remote do
116-
it "Uses Wires when setting marionette option in driver initialization" do
117-
@opt[:marionette] = true
118-
driver1 = Selenium::WebDriver.for GlobalTestEnv.driver, @opt
115+
it "Uses Wires when setting marionette option in driver initialization" do
116+
@opt[:marionette] = true
117+
driver1 = Selenium::WebDriver.for GlobalTestEnv.driver, @opt
119118

120-
expect(driver1.capabilities[:takes_element_screenshot]).to_not be_nil
121-
driver1.quit
122-
end
119+
expect(driver1.capabilities[:takes_element_screenshot]).to_not be_nil
120+
driver1.quit
123121
end
124122
end
125123

rb/spec/integration/selenium/webdriver/spec_support/test_environment.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ def create_firefox_driver
215215
end
216216

217217
def create_marionette_driver
218-
binary = ENV['MARIONETTE_BINARY']
218+
binary = ENV['FIREFOX_BINARY']
219219
WebDriver::Firefox.path = binary if binary
220220

221221
WebDriver.for :firefox, :marionette => true

rb/spec/integration/selenium/webdriver/target_locator_spec.rb

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,12 @@
2828

2929
# https://github.com/jgraham/wires/issues/52
3030
not_compliant_on :browser => :marionette do
31-
it "should find the active element" do
32-
driver.navigate.to url_for("xhtmlTest.html")
33-
expect(driver.switch_to.active_element).to be_an_instance_of(WebDriver::Element)
31+
# https://github.com/SeleniumHQ/selenium/issues/1795
32+
not_compliant_on :driver => :remote, :browser => [:edge, :marionette] do
33+
it "should find the active element" do
34+
driver.navigate.to url_for("xhtmlTest.html")
35+
expect(driver.switch_to.active_element).to be_an_instance_of(WebDriver::Element)
36+
end
3437
end
3538
end
3639

0 commit comments

Comments
 (0)