Stop skipping window tests and pend #maximize tests for headless Chrome

This commit is contained in:
Thomas Walpole 2018-11-26 09:54:00 -08:00
parent 127999fec2
commit 12c0651548
5 changed files with 2 additions and 9 deletions

View File

@ -12,8 +12,6 @@ env:
global:
- NOKOGIRI_USE_SYSTEM_LIBRARIES=true
- JAVA_OPTS=-Djava.security.egd=file:/dev/urandom
# matrix:
# - WINDOW_TEST=true
addons:
apt:

View File

@ -30,8 +30,6 @@ module TestSessions
end
skipped_tests = %i[response_headers status_code trigger]
# skip window tests when headless for now - closing a window not supported by chromedriver/chrome
skipped_tests << :windows if ENV['TRAVIS'] && (ENV['SKIP_WINDOW'] || ENV['HEADLESS'])
$stdout.puts `#{Selenium::WebDriver::Chrome.driver_path} --version` if ENV['CI']
@ -39,6 +37,8 @@ Capybara::SpecHelper.run_specs TestSessions::Chrome, CHROME_DRIVER.to_s, capybar
case example.metadata[:full_description]
when /#click_link can download a file$/
skip 'Need to figure out testing of file downloading on windows platform' if Gem.win_platform?
when /Capybara::Session selenium_chrome Capybara::Window#maximize/
pending "Chrome headless doesn't support maximize" if ENV['HEADLESS']
end
end

View File

@ -60,8 +60,6 @@ TestSessions::Chrome.driver.browser.file_detector = lambda do |args|
end
skipped_tests = %i[response_headers status_code trigger download]
# skip window tests when headless for now - closing a window not supported by chromedriver/chrome
skipped_tests << :windows if ENV['TRAVIS'] && (ENV['SKIP_WINDOW'] || ENV['HEADLESS'])
Capybara::SpecHelper.run_specs TestSessions::Chrome, CHROME_REMOTE_DRIVER.to_s, capybara_skip: skipped_tests do |example|
case example.metadata[:full_description]

View File

@ -42,7 +42,6 @@ module TestSessions
end
skipped_tests = %i[response_headers status_code trigger]
skipped_tests << :windows if ENV['TRAVIS'] && ENV['SKIP_WINDOW']
$stdout.puts `#{Selenium::WebDriver::Firefox.driver_path} --version` if ENV['CI']

View File

@ -56,8 +56,6 @@ TestSessions::RemoteFirefox.driver.browser.file_detector = lambda do |args|
end
skipped_tests = %i[response_headers status_code trigger download]
# skip window tests when headless for now - closing a window not supported by chromedriver/chrome
skipped_tests << :windows if ENV['TRAVIS'] && (ENV['SKIP_WINDOW'] || ENV['HEADLESS'])
Capybara::SpecHelper.run_specs TestSessions::RemoteFirefox, FIREFOX_REMOTE_DRIVER.to_s, capybara_skip: skipped_tests do |example|
case example.metadata[:full_description]