Wait = Selenium::WebDriver::Wait.new(:timeout => 15)Įlement = wait. Options.add_preference('download.dir', 'application/pdf, application/, application/vnd.ms-excel, text/csv')ĭriver = Selenium::WebDriver.for :firefox, capabilities: optionsĭ_wait = 10 # seconds Options.add_preference('download.prompt_for_download', false) Options.add_preference('download.folderList', 2) Options.add_preference('download.directory_upgrade', true) Profile = Selenium::WebDriver::Firefox::Options.new(profile: profile) MacBook, Mac OS X (10.6.8), Build 10K549 Posted on 8:23 AM Reply I have this question too ( 5 ) I have this question too Me too (5) Me too. Profile = Selenium::WebDriver::Firefox::Profile.new Download Current version for Mac OS X 10.6 Snow Leopard: 52.9.1p1 () Note: the program is called 'Nightly' due to licensing restrictions prohibiting the use of the official Firefox. Selenium:: = File.join(Dir.pwd, "lib/forecastdownloads")įileUtils.mkdir_p # Create the folder if missing This is my current code, which has attempts to change the directory in four places (any help much appreciated): require 'selenium-webdriver' I am having trouble getting Selenium to download files to the specified folder on MacOS.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |