Is it possible to setup a coded step to run another test before continuing.
Use case is: There are some setup tests that need to be ran before other tests.
A coded step to call those tests first would be ideal, is there a solution for this?
Thanks
5 Answers, 1 is accepted
Thank you for this question. It is possible to add a coded step that could be placed for execution as initial to the test. There is an article that you might find useful that provides a sample on how to run an API test in a coded step. I hope this would do in your scenario.
Best Regards,
Nikolay Petrov
Progress Telerik

That is perfect, thanks for the link to the documentation that covers this.
One more thing though: When I use the code in the example, I get a compile error:
'The type or namespace name 'Process' could not be found (are you missing a using directive or an assembly reference?)'
How is this resolved?
The Process is located in the System.Diagnostics namespace. To resolve this compilation problem you could either add a using to it on the top of the code behind file where other usings are (using System.Diagnostics;) or to change Process to System.Diagnostics.Process statement.
I hope that would resolve the problem.
Best Regards,
Nikolay Petrov
Progress Telerik

Thanks for the reply.
I have tried both of those solutions.
Adding 'using System.Diagnostics.Process;' did not resolve the issue.
Neither did adding the statement.
What I did notice is intellisense is not even showing Process as an option. This is part of my confusion.
It is correct that at this point - if not perform additional actions the Process will not appear in the Diagnostics namespace. You have probably seen in the "Project Properties" dialog that there is already a reference to "System". This is misleading though since this is actually the reference to mscorlib, but with a wrong label. So your project actually does not have a reference to System.dll.
To workaround this issue, you simply need to manually add your references with absolute path to the desired dlls in the project.settings file. You can add your reference like it is shown on the attached screen-shot. Then you should be able to use all related classes.
I hope this would fix the problem.
Best Regards,
Nikolay Petrov
Progress Telerik