How to set the script to use different username/password/proxies for different servers

Using different username/password/proxies for different servers

1. If there is a different proxy, use web_set_proxy to change the information:

  1. If the protocol is HTTP, use

web_set_proxy("proxyname:<port>");

  1. If the protocol is HTTPS, use

web_set_secure_proxy("proxyname:<port>");

2. If you need to change the username/password as well, use the web_set_user to change the information:

web_set_user("username","password","proxyname:<port>");

3. In the script, parameterized the server name. Basically, you will just need to change any hard coded URLs and Server IPs to point to the new server. This will work assuming both servers are exactly the same in terms of the application under test.

Leave a Comment