Hi,
I have a problem I need to use in one test, the data of the other test.
I read this link http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/data-driven-testing/multi-level-tests.aspx but my test aren’t sequential.
I want to know if exist any way transform one variable in global and use in all project.
I tried use data source, but the content of my excel file isn’t update.
The content of variable I need global is: text concatenate with actual date, are started the test.
5 Answers, 1 is accepted
yes, this is doable. Check out the following article which demonstrates this approach:
http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/code-samples/general/utility-in-standalone.aspx
Regards,
Stoich
the Telerik team
Thanks for your help.
I have one more question, exist any way to define a relative path for the file be added in folder the test project?
Which file exactly are you referring to?
All the best,Cody
the Telerik team
Hello Cody. I hope you have had a nice day.
Sorry you're right. I didn’t explain myself very well. Your colleague Stoich suggested using a file with global variables. The example of this file is present in http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/code-samples/general/utility-in-standalone.aspx .
My question is I want save the file inside the folder of the test project, but I like using the relative path for the test run on all computers and thus allowing it to be independent of the location of the folder.
You can place your class file anywhere in the Test Studio project folder. If your test project is at:
C:\My Test Projects\Test Project A
Place your file in the folder "Test Project A", or if you prefer to separate files, in a subfolder under it:
C:\My Test Projects\Test Project A\Utility Classes
Test Studio will automatically pick up and compile any/all source code files it finds when it builds the test project (the build happens automatically when you go to execute the test).
Cody
the Telerik team