I have Hybrid Framework using Selenium Webdriver that successfully executes test cases against Firefox, Chrome and IE. Now, I wanted to run this entire suite using Browserstack. However, when I try to access the application I make entries in the host file - the ipaddress and the host name. This makes sure that I'm hitting the exact server. Using Java code on https://www.browserstack.com/automate/java I'm able to execute a sample script. However, how can I pass the ipaddress mapping of my application to my Selenium instance when executing it on Browserstack?
Asked
Active
Viewed 868 times
0
-
There are several code segments at that URL; are you using them all? – Politank-Z Jun 02 '15 at 15:45
-
I used the one under "Getting started". – FunkyGorillas Jun 02 '15 at 15:46
1 Answers
0
The BrowserStack Local Testing feature (https://www.browserstack.com/local-testing) should help you test your private servers configured in your hosts file. Please follow these steps:
1) Download and execute the Local Testing binaries (https://www.browserstack.com/local-testing#command-line) using the following command:
./BrowserStackLocal ACCESS_KEY -forcelocal
The '-forcelocal' parameter will route all traffic via your machine which allows you to test servers configured in your hosts file on BrowserStack.
2) Add the capability 'browserstack.local'='true' in your test scripts and execute them.