How do I create an exe for a subsection of my test cases?

Ranorex Spy, Recorder, and Studio.
houseofcutler
Posts: 52
Joined: Fri Mar 21, 2014 4:22 pm

How do I create an exe for a subsection of my test cases?

Post by houseofcutler » Thu Jun 19, 2014 3:24 pm

Hi There,

I have already created a regression suite for a web based application my company develops. This is all contained within a single project.

I have now been asked to create a Ranorex test we can use for a continuous status check - essentially the exe needs to be scheduled to run at regular intervals and output something we can pick up with some other monitoring facilities. This in itself is all fine however I have been trying to work out how to do this without having to build all new modules.

Most of what I need has already been done, but having done some searching for information on this I am still not really very clear on the correct way to work with multiple projects in a solution.

Essentially I just want to be able to reuse a bunch of my modules and run them (via and eve) independently of the whole solution.

So far it looks as though I have to copy the repository and modules to the new project but I am not sure if this is actually the correct thing to do.

Could someone please advise the best (easiest) way to achieve what I need please? (Or direct me to the appropriate documentation/post)

Many thanks

Ben

houseofcutler
Posts: 52
Joined: Fri Mar 21, 2014 4:22 pm

Re: How do I create an exe for a subsection of my test cases?

Post by houseofcutler » Thu Jun 19, 2014 3:47 pm

Update - I discovered that by using run configurations you can alter the test cases included in the EXE file generated in debug\bin http://www.ranorex.com/support/user-gui ... html#c3019

Using this will allow me to do what I need to for the scheduled status tests.

However I would still like some advise on when it is appropriate and most useful to use multiple projects and whether these should all have separate repositories etc.

Thanks

Ben

krstcs
Ranorex Guru
Posts: 2683
Joined: Tue Feb 07, 2012 4:14 pm
Location: Austin, Texas, USA

Re: How do I create an exe for a subsection of my test cases?

Post by krstcs » Thu Jun 19, 2014 4:27 pm

Ben,

I normally have multiple projects when there are distinct and divergent business paths through the application. I make a new project for each path.

For example, on our e-commerce site, you can checkout while logged out or logged in. For the most part they are the same, but there are some very distinct differences that could not be overcome in a single test suite. So, I created one Test Suite Project for each. But, I have one CORE project that contains all of the modules and the repository so any module can be used in any other test suite/project. The only exception to this is modules that are made specifically for a given suite/project. I place those in the project they should go in.

Our solution looks like this (although a bit bigger):
WEB_CORE (contains the modules and repo, but the suite is not normally run as a direct test)
WEB_GuestUserPurchase
WEB_LoggedInUserPurchase
WEB_SmokeTest

Because of my extensive use of SQL this makes creating the test a little more complex, but in the end I have fewer test suites that I have to maintain. Combined with simple, atomic-action (as few actions in a module as possible) modules, it makes for a very powerful, but drag-and-drop capable, test framework.
Shortcuts usually aren't...

houseofcutler
Posts: 52
Joined: Fri Mar 21, 2014 4:22 pm

Re: How do I create an exe for a subsection of my test cases?

Post by houseofcutler » Fri Jun 20, 2014 11:53 am

Hi Krstcs,

Thank you for taking the time to explain that - Your set up - particularly the really small and portable modules does sound like the ideal way to use this system - I wish I had known more about your set up before I started!

I thought I had this all sorted now but when trying to run the tests I am getting a 'Cyclic dependency issue' I am not able to see where the problem with the reference is though.

I have removed everything from the rxtxt for the new project - there is only the top level test suite and I am still getting the dependency error.

I found this old forum post - http://www.ranorex.com/forum/project-de ... t1703.html which talks about creating class libraries (which I don't really know about).

I haven't done any thing with code in my existing project other than add some user code to my recording modules - is this causing the issue?

Sorry for all the questions but it seems this is rather crucial to configuring the solution to be used in the best possible way going forward.

Many thanks

krstcs
Ranorex Guru
Posts: 2683
Joined: Tue Feb 07, 2012 4:14 pm
Location: Austin, Texas, USA

Re: How do I create an exe for a subsection of my test cases?

Post by krstcs » Fri Jun 20, 2014 2:42 pm

Without seeing your solution, I wouldn't be able to tell you exactly where you circular dependency is.

That error means that you have two projects referencing each other, which is not allowed. The system has to be able to build the dependent project after the one it depends on.

Check each project's "References" folder and make sure that they aren't referencing each other.
Shortcuts usually aren't...