Watir with webdriver, proxy, Firefox

前端 未结 3 847
小鲜肉
小鲜肉 2021-01-17 01:15

I am able to use watir-webdriver with IE, but I would prefer to use Firefox. Problem: I need a proxy. By googling around, I found some code snippets, but I am not able to pu

3条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-17 02:12

    profile = Selenium::WebDriver::Firefox::Profile.new
    profile.proxy = Selenium::WebDriver::Proxy.new :http => '12.12.12.12:8888', :ssl => '15.15.15.15:443'
    browser = Watir::Browser.new :firefox, :profile => profile
    

提交回复
热议问题