问题
I am trying to pass cookies option for Chrome Drive using Watir gem
From Watir documentation i can do Watir::Browser.new :chrome, opts
So for cookies I can do:
browser = Watir::Browser.new :chrome, options: {args: ['--user-data-dir=/cookies']}
When using the webdriver-user-agent gem for mobile testing, their documentation tells me to start the browser like this:
driver = Webdriver::UserAgent.driver(browser: :chrome, agent: :iphone)
browser = Watir::Browser.new driver
But now I don't know how I can pass the option for the Chrome
来源:https://stackoverflow.com/questions/57864543/how-to-pass-chrome-options-in-webdriver-user-agent-gem-for-watir