Help! Multiple Test Suite Files in Assembly directory error

Ranorex Spy, Recorder, and Studio.
puniar
Posts: 20
Joined: Thu Jan 24, 2019 12:51 pm

Help! Multiple Test Suite Files in Assembly directory error

Post by puniar » Wed Feb 03, 2021 12:32 pm

Hello,

I have a solution containing multiple projects and each of these projects contain multiple test suites.

I use the command to execute the test suites using the CLI in azure. There are many such test suites which are executing without any errors but there is one particular project and related test suites which fail with the following error code.


Unexpected exception occurred: Ranorex.RanorexException: There are multiple test suite files in the assembly directory. Please specify the test suite by using command line parameters or rename the test suite file to the current assembly name.
at Ranorex.Core.Testing.TestSuiteRunner.GetTestSuiteXml(Type containerType, String fileName)
at Ranorex.Core.Testing.TestSuiteRunner.Run(Type containerType, String cmdLineArgs, String testSuiteXml)
at Settings.Program.Main(String[] args)

Command:TestSuite.exe /ts:Testsuite.rxtst /junit /zr /zrf:Reports/ExportImportDex.rzlog

I have verified the Assembly name for the project and see no issues on it.
CurrentStructure.PNG
CurrentStructure.PNG (30.76 KiB) Viewed 216 times
Regards,
Punith

User avatar
Stub
Posts: 443
Joined: Fri Jul 15, 2016 1:35 pm

Re: Help! Multiple Test Suite Files in Assembly directory error

Post by Stub » Wed Feb 03, 2021 1:06 pm

Specify the full path and filename of the TestSuite file on the /ts parameter.

puniar
Posts: 20
Joined: Thu Jan 24, 2019 12:51 pm

Re: Help! Multiple Test Suite Files in Assembly directory error

Post by puniar » Tue Mar 02, 2021 5:27 am

Hello Stub,

That too didn't work, I tried with the full path where the exe and test suite were placed. But the error still continued.
Any other alternatives to check for the issue
Regards,
Punith

alena_s
Posts: 1
Joined: Thu Mar 30, 2017 2:30 pm

Re: Help! Multiple Test Suite Files in Assembly directory error

Post by alena_s » Fri Mar 19, 2021 4:58 pm

Hi,

I'm interested in the solution as well.

Thanks!

tam
Posts: 1
Joined: Fri Apr 23, 2021 6:54 am

Re: Help! Multiple Test Suite Files in Assembly directory error

Post by tam » Fri Apr 23, 2021 7:31 am

Hello,
I've been struggeling with this error too and I figured out that it basicly means that the Testsuite that you have given via the parameter can't be found (for example if you write /ts:Testsuite instead of /ts:Testsuite.rxtst). Which honestly would be nice to have a different error for, but this is what we have.

My problem was in the end that I just had wrong "" in the powershell script that started the exe. So maybe this helps someone in the future who has a similar problem.
Original (Wrong):
& $testExecutable "/ts:$testSuite /pa:RxParameter=$Parameter"
Correct:
& $testExecutable "/ts:$testSuite" "/pa:RxParameter=$Parameter"

As to the problem of the original poster, I would suggest trying just the /ts parameter (remove the other parameters from your command for a test), if that in itself causes a problem, or if it may be the combination of the different parameters that actually causes the problem.