Execute multiple projects in 1 solution

Ranorex Spy, Recorder, and Studio.
PeterM
Posts: 9
Joined: Mon Jan 16, 2012 11:52 am

Execute multiple projects in 1 solution

Post by PeterM » Fri Sep 06, 2013 2:55 pm

Dear Support!

I have a solution containing multiple projects. So, when I build the solution, it will create the executables for each project under the corresponding \bin\debug.

What is the best practice to execute all projects at once?
It would be important, that if 1 project fails (meaning the testcases or at least 1 testcase in it), the rest of the projects shall be executed anyway.
Also, it would be nice if only 1 report was generated.

Is there a best practice for that?

Many thanks in advance
Peter

PeterM
Posts: 9
Joined: Mon Jan 16, 2012 11:52 am

Re: Execute multiple projects in 1 solution

Post by PeterM » Mon Sep 09, 2013 11:38 am

Dear Support!

I found an existing post on this:
http://www.ranorex.com/forum/how-to-run ... t1666.html

I followed the steps and it seems to be ok. Testcases executed after each other, and only 1 report is generated. However, there is 1 question remaining:
Is it possible to generate the report so that each ranorex test suite/test project is indicated somehow above the corresponding testcases? I.e.: the report now contains all testcases one after the other, but I can't tell at first glance to which project/ranorex test suite they belong to.

Many thanks in advance
Peter

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Execute multiple projects in 1 solution

Post by Support Team » Tue Sep 10, 2013 3:53 pm

Hello Peter,

Unfortunately there is no easy way to show the project in the report automatically because the solution in the post "How to run multiple project " is just a workaround and uses Ranorex internal methods.
As workaround you can use a Report.Info("Current project") and write the Project name into the Report. Another possibility is to create a "main" Test Case in the project which contains all other Test Cases. Use the name of the project as part of the name of the Test Case.

For example:
Main Test Case Project1
- Working Test Case 1
- Working Test Case 2
- Working Test Case 3
...

I hope this is a suitable workaround for you.

Regards,
Bernhard
.
Image

PeterM
Posts: 9
Joined: Mon Jan 16, 2012 11:52 am

Re: Execute multiple projects in 1 solution

Post by PeterM » Thu Sep 12, 2013 12:45 pm

Hi Bernhard,

Thank you for the tip, will try that and see if its suitable at the moment.

I have another question though on the main workaround for executing multiple projects at once.
With this way of merging the reports to 1 report, sometimes the final report is just empty. However if I execute it again, it gets ok, filled with the correct information. But from time to time, it happens that it is just empty. Have you faced such behavior? May be something with the report merging?

Many thanks
Peter

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Execute multiple projects in 1 solution

Post by Support Team » Fri Sep 13, 2013 1:50 pm

Hello,

It is hard to analyze the issue if it only occurs sometimes.
What do you mean with "the report is empty"? Is there a warning like "Data file (*.rxlog.data) not found." when you open the report? Could you please check if there is a file with the extension *.rxlog.data_tmp in your report directory? If this is the case please rename it to *.rxlog.data.
Could you post a report file if this happens again?

Regards,
Bernhard
.
Image