We have created UI tests using the DEV plugin.
The Project code gets committed to SVN and then the Test is executed via Bamboo as a task using ArtofTest.Runner:
C:\Program Files (x86)\Progress\Test Studio\Bin>ArtOfTest.Runner list="D:\Bamboo
The test execution does start and the tests gets executed but once the browser is openend , there is an error message : Localhost refused to connect.
TestStudio_Runtime_2020_2_0910_1 is installed and configured on the machine that execute the test.
Please see attached screengrab.
5 Answers, 1 is accepted
Thank you for the thorough description of what you are trying to accomplish - this is really helpful for me to provide you additional details on the case.
It seems that something on the particular machine prevents the communication between the Test Studio execution process and the browser. There are few things to verify on your end to drill down what is causing the misbehavior. Please, take the time to review the below points and let me know your findings:
- Is there an active firewall on the machine, which will execute the tests through Bamboo?
If yes, please, try to deactivate it for a while and check if the test execution will start as expected through the Bamboo task.
- If there is any antivirus software, it could be also preventing the Test Studio ArtOfTest.Runner.exe to start as expected. So, please, check this possibility as well.
- If none of the above is applicable, please, trigger a test run through the Bamboo task and when you get to the state from the screenshot, open the Windows Task Manager. In its Details tab there should be a Test Studio process called Telerik.TestingFramework.Hosts.Manager - do you see such one?
- In case this process is not started, please, enable the logging from the Test Runner and execute the Bamboo task once again. Once the browser returns the same message that the localhost cannot be reached, you can close it and then collect the log generated so far. Please, send this zipped via this thread.
As a side note in this discussion, I would like to point your attention to a possible issue you may encounter - as the Test Studio tests are functional UI tests, these require an active desktop session to be correctly executed. Therefore, the Test Studio Run-time client allows you to control the user session on the remote machine and keep it unlocked and active. You can find some additional details on the topic here.
Please, let me know what is the outcome of the above mentioned suggestions. Thank you in advance for your cooperation.
1. I have disabled the firewall and and did not make a difference.
2. The Antivirus software has been disabled and did not make a difference.
3. I have enabled the logging and have attached the log.
Could it be that the localhost is not resolving?
Thank you for your prompt reply.
My next suggestion corresponds to your additional query, actually - have you modified the hosts file on this Bamboo machine? Or, is there any other mechanism you are using to change how localhost gets resolved in the network?
Can you, please, check if the Telerik.TestingFramework.Hosts.Manager process gets started when the test run is triggered? This will be also an interesting finding in case there are no rules for how localhost is resolved.
Thank you once again for your cooperation.
Thanks for these additional details provided.
As of Test Studio perspective there is no obstacle for the test run to be initiated -based on the logging the web socket and file server are successfully started on browser side and the Telerik.TestingFramework.Hosts.Manager process from Test Studio client is also active. However, the communication between these components is somehow prevented.
There is a side note about the hosts file - in the screenshot you shared there is a 'S' at the end of its last row. I guess that this is added by mistake when saving the file, but it still worth it to check if this is not causing troubles.
And since you checked the firewall, antivirus and the hosts file, which doesn't seem to be an issue for the current case, can you, please, check if there is anything specific in the machine configuration, which could be affecting the resolving of localhost? Possibly, you may need to consult with your IT administration for further details on this topic.
One more possible cross check could be to install a Test Studio instance on this particular machine and verify if recording and quick execution are possible. I understand that this may take some additional time to test, but I will appreciate if you can perform it. If you decide to give this a try, you will probably need to switch a license to that machine - here is how you can do this.
Please, let me know about any findings you manage to sort out on the case. Thank you once again for the time you spent in our discussion.