kanbanworkflowstimelinescrumrubyroadmapproject-planningproject-managementopenprojectangularissue-trackerifcgantt-chartganttbug-trackerboardsbcf
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1023 B
37 lines
1023 B
8 years ago
|
require 'capybara/rspec'
|
||
|
require 'rack_session_access/capybara'
|
||
|
|
||
|
RSpec.configure do
|
||
|
Capybara.default_max_wait_time = 4
|
||
|
Capybara.javascript_driver = :selenium
|
||
|
end
|
||
|
|
||
|
Rails.application.config do
|
||
|
config.middleware.use RackSessionAccess::Middleware
|
||
|
end
|
||
|
|
||
9 years ago
|
Capybara.register_driver :selenium do |app|
|
||
|
require 'selenium/webdriver'
|
||
|
|
||
|
Selenium::WebDriver::Firefox::Binary.path = ENV['FIREFOX_BINARY_PATH'] ||
|
||
8 years ago
|
Selenium::WebDriver::Firefox::Binary.path
|
||
9 years ago
|
|
||
9 years ago
|
capabilities = Selenium::WebDriver::Remote::Capabilities.internet_explorer
|
||
|
capabilities["elementScrollBehavior"] = 1
|
||
|
|
||
9 years ago
|
profile = Selenium::WebDriver::Firefox::Profile.new
|
||
|
profile['intl.accept_languages'] = 'en'
|
||
|
|
||
8 years ago
|
profile['browser.download.dir'] = DownloadedFile::PATH.to_s
|
||
|
profile['browser.download.folderList'] = 2
|
||
|
|
||
|
profile['browser.helperApps.neverAsk.saveToDisk'] = 'text/csv'
|
||
|
|
||
9 years ago
|
Capybara::Selenium::Driver.new(
|
||
|
app,
|
||
|
browser: :firefox,
|
||
|
profile: profile,
|
||
|
desired_capabilities: capabilities
|
||
|
)
|
||
9 years ago
|
end
|