Forum Discussion

vgundavarapu's avatar
vgundavarapu
New Contributor
14 years ago

Can Project level vairables be shared among individual task runs

Our app is a Winforms App
with embedded Infragistics Controls. The object tree model dynamically
changes per application launch instance, i.e some objects'
MappedName/Full Name property is different everytime application is
launched.

To work with this application, we are setting objects' handles
dynamically after the application is launched as Project Level
variables. There are few methods in our project that need to run on a
slave machine. To do this, we are calling the Tasks from within a script
whenever needed.

Order is something like this:

Sub Master()

Execute master method 1.

Execute Slave Task1 - Launches app and Sets all the project level variables on slave computer.

Execute master method 2

Execute Slave Task2 - During this execution the Project level variables
appear to be unassigned or are not available for the methods.

End Sub



The project level variables are of Object Type. So I believe I cannot use NetworkSuite variables to accomplish the task.

Is there a way to share project level variables between task runs? Or anything else that we could do achieve our goal.

Master computer uses Testcomplete and slave computer is running Test Execute.

1 Reply


  • Hi Viswa,





    As far as I understand, you want to keep object references from one test run to another on a slave machine. Please let me know if I am wrong.





    If you are using the Name Mapping feature, I recommend that you map the problematic objects by the properties with variables values. You can specify a persistent project variable as a value of such a property. Since such variables keep their values between test runs, this scheme will allow you to get access to a valid object by its mapped name.





    Another solution is to have a single test on a remote machine. In this case, you will need to run this remote test at the beginning of the test on the master machine and synchronize tests on both machines using synchronization points. More information can be found in the Synchronization Points help topic.