Page 1 of 1

Input parameters are not passed in Remote Agent Test esecution

Posted: Thu Mar 21, 2019 2:58 pm
by mafi
Hi All,
I tried to remotely execute a test suite on a remote agent.
The local machine is W10Pro with Ranorex 9.
The remote machine is W10Home with Remote agent installed.
Running test suite on local machine everything works fine.
Trying to run the same test suite on the remote machine, test fails because variables (like application path) do not get the assigned parameters.
The values to variables are passed by code.
I noticed that the "config.properties" file from which the code reads the parameters is not included in the build and cannot be found by built project.
In fact, coping back the deployed folder on the local machine, I have the same problem, due to the missing config.properties file.
How could I solve the issue?
What should I check out?

Attached you can find a log for your reference.
Thank you in advance for your support.
RnxRemAgVar_Log.PNG

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Fri Mar 22, 2019 12:21 pm
by odklizec
Hi,

The config.properties is something you added to the project? Are you sure you marked this file as "included" and enabled "copy to output directory=always"?...
viewtopic.php?f=20&t=13413&p=52728#p52728

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Fri Mar 22, 2019 2:36 pm
by mafi
Yes, the file has been added to the project and it is read at the beginning.
It works locally, but doesn't deploying the solution, because the file is not found.
I read that post and I had already tried to add it in the output dir, but the file (build.properties) and its location (Solution items) do not allow to access to properties and then there is no way to modify those parameters.
Even trying to move the file in other folders of the solution from Ranorex Studio UI, it cannot be moved at all.

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Mon Mar 25, 2019 1:41 pm
by McTurtle
Hello mafi,

If the "Copy to output" setting is set to "Always" and it is found when building locally but not found when building in your deployment process, then it is probably not committed to the source control system. Can you check if the file is in the remote repo?

Regards,
McTurtle

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Mon Mar 25, 2019 2:26 pm
by mafi
Hi McTurtle,
thank you for your post.
f the "Copy to output" setting is set to "Always" and it is found when building locally but not found when building in your deployment process, then it is probably not committed to the source control system. Can you check if the file is in the remote repo?
Unfortunately I cannot find any repo file into remote folder. Should it be present with the same "rxrep" file extension?
probably not committed to the source control system
How can I check this?

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Tue Mar 26, 2019 8:47 am
by Stub
My repositories have a .rxrep and .rximg file pairing. There's also a RanorexStudio generated .cs file that goes along with them, which I also store in source control, along with the other two files - because our setup uses MSBuild to build the Ranorex solution; we don't use Remote Agent. Three files in all per repository for me here.

Checking what's in your source control will depend on what your source control system happens to be. How familiar with that are you?

Re: Input parameters are not passed in Remote Agent Test esecution

Posted: Tue Mar 26, 2019 12:49 pm
by mafi
I solved the problem just moving the file from "Solution itmes" folder to Test case subfolder. In this way I have been able to access to the file properties and, setting "Build action = EmbeddedResource" and "Copy to output directory=Always", the deployed solution was able to find the reference and then the values.

So just moving the file in the right place, setting the right properties for it and properly addressing it in the code, there is no problem in remote agent running.

Sorry for disturbing and thank you for your support.