Watir Tutorial
Selected Reading
- Watir - Discussion
- Watir - Useful Resources
- Watir - Quick Guide
- Watir - Browser Windows
- Watir - Downloads
- Watir - Alerts
- Watir - Proxies
- Watir - Cookies
- Watir - Page Performance
- Watir - Page Objects
- Watir - Capturing Screenshots
- Watir - Mobile Testing
- Watir - Headless Testing
- Watir - Automatic Waits
- Watir - Working with Iframes
- Watir - Locating Web Elements
- Watir - Web Elements
- Watir - Working with Browsers
- Watir - Installing Drivers for Browsers
- Watir - Environment Setup
- Watir - Introduction
- Watir - Overview
- Watir - Home
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Watir - Proxies
Watir - Proxies
Watir允许在需要与浏览器使用的替代物体的帮助下使用代理。
Syntax
proxy = { http: 127.0.0.1:8080 , ssl: 127.0.0.1:8080 } b = Watir::Browser.new :chrome, proxy: proxy
关于如何使用 proxy- b浏览器的例子如下:
Example
require "watir" proxy = { http: 127.0.0.1:8080 , ssl: 127.0.0.1:8080 } b = Watir::Browser.new :chrome, proxy: proxy b.goto google.com b.screenshot.save proxy.png
我们使用了下文所示代理物体:
proxy = { http: 127.0.0.1:8080 , ssl: 127.0.0.1:8080 }
代理人地址细节将同时用于https和sl。 我们可以使用下文所示的幼苗 b。
b = Watir::Browser.new :chrome, proxy: proxy
产出代理。 页: 1
下文将讨论如何使用代谢物的例子。
Example
require "watir" proxy = { http: 127.0.0.1:8080 , ssl: 127.0.0.1:8080 } b = Watir::Browser.new :firefox, proxy: proxy b.goto google.com b.screenshot.save proxyfirefox.png
您可以补充以下代理细节:
proxy = { http: 127.0.0.1:8080 , ssl: 127.0.0.1:8080 } b = Watir::Browser.new :firefox, proxy: proxy
此处显示的是产出代理火焰。
Advertisements