Ranorex/SVN - Test Suite Merging

Ranorex Studio, Spy, Recorder, and Driver.
AccidentReport
Posts: 78
Joined: Tue Dec 04, 2012 2:30 pm

Ranorex/SVN - Test Suite Merging

Post by AccidentReport » Wed Nov 26, 2014 2:00 pm

Is there an easy way to resolve conflicts with the test suite file when performing updates via SVN?

There are currently two users working on a single Ranorex project and we are finding it difficult to get the test suite files to merge correctly. The issue seems to be that we have a number of folders in the test suite for different areas of testing. one user is updating a folder near the top of the list and the other is working on one near the bottom. When we do a merge SVN is basically trying to match up lines and ends up trying to insert bits where they shouldn't be and resulting in an invalid XML file.

Is there an easier or better way to do this?

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

Re: Ranorex/SVN - Test Suite Merging

Post by krstcs » Wed Nov 26, 2014 3:01 pm

Is there an easier/better way? Yes, don't work on the same Test Suite at the same time.

You can create multiple projects and keep all of your modules in the first one, and then have the others just be the suites for each type of test. This is what I do and it works wonderfully. Just have everyone work on their own projects, but they need to add all code and Recording Modules to the original project. (When you create a new project, you have to make sure you select "Ranorex C# Test Suite" in the "C#" root folder of the Create Project window, instead of the default "Ranorex C# Test Library".) I usually name my Solutions and Projects like this:

Code: Select all

TCS_WEB (solution)
    TCS_WEB_CORE (module and repository holder, use the Suite only for testing modules, it's a sandbox)
    TCS_WEB_LoggedInPurchase (Test Suite for the Logged In Purchase regression)
    TCS_WEB_GuestPurchase (Test Suite for the Guest Purchase regression)
    TCS_WEB_SmokeTest (Test Suite for the Smoke Test)
This allows us to each work on separate suites and not have too many problems with merges.

As for resolving conflicts once you are already merging, there is no easy way to do it. You might need to roll back the merge and update one copy or the other with the opposite copy's work and then merge.

Edit: Also, it depends on how SVN marks merge areas as well. With Git it's pretty easy to see the differences as they are marked one over the other. Just select on and delete it.
Shortcuts usually aren't...

AccidentReport
Posts: 78
Joined: Tue Dec 04, 2012 2:30 pm

Re: Ranorex/SVN - Test Suite Merging

Post by AccidentReport » Wed Nov 26, 2014 3:10 pm

YesI was already thinking down that line. Thanks for confirming my thoughts. I think we'll create seperate project and break the work up a bit.

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

Re: Ranorex/SVN - Test Suite Merging

Post by krstcs » Wed Nov 26, 2014 3:18 pm

Yeah, I have similar issues sometimes with Git. The XML in Ranorex causes issues.

Branch often.
Commit small changes often.
Merge master into your branch after each commit. (Note: Merge master into YOUR BRANCH, not the other way around... That causes no end of headache and pain... Just don't ask me how I know... :oops: )
When you're done with your work, then make sure it works and merge it into master.
Shortcuts usually aren't...