基于信息here,有针对Firefox 5种不同的代理服务器配置:
0
Direct connection, no proxy. (Default in Windows and Mac previous to 1.9.2.4 /Firefox 3.6.4)
[edit]
1
Manual proxy configuration.
[edit]
2
Proxy auto-configuration (PAC).
[edit]
4
Auto-detect proxy settings.
[edit]
5
Use system proxy settings. (Default in Linux; default for all platforms, starting in 1.9.2.4 /Firefox 3.6.4)
它看起来像“0”是一个你需要的。我们设置为在Watir-Webdriver help page for Firefox描述:
profile = Selenium::WebDriver::Firefox::Profile.new
profile["network.proxy.type"] = 0
browser = Watir::Browser.new :firefox, :profile => profile
所有的个人资料[“Lorem存有”]的类型选项都在约上市:在Firefox配置菜单的URL,并访问/以类似的方式改变。
这个问题是关于Firefox在Ruby中使用'Watir'宝石时没有按预期开始的。因此,我认为这不应该被视为“脱离主题”。 –
我同意。浏览器配置文件设置是“Watir”测试中的日常主题。 –