Page 1 of 1

TestSuit Setup

Posted: Fri Aug 10, 2018 8:40 pm
by LicFAF
Hi,
Having the following structure:

TESTSUITE
|-TS_setup
--- SMARTFOLDER
|-SF_setup
--- TESETCASE1
|-Recording1
|-Recording2
|-Recording3

We are running tests through CMD (command line) like this: SomeTest.exe /tc:sometc
c:\tests\TESTSUITE.exe /TC:TESTCASE1

When the test starts the testsuit setup and the smartfolder setup are avoided and the test starts from Recording1. If I use the TestCase1 setup it runs fine but we are testing a webpage and the SF_setup login to the web application and then the rest of the teset cases just do the validations. I need to login 1 time only and do the validations for every testcase.

This "issue" starts with Ranorex 8.x the previous version execute all setups before starting the TESTCASE1
Is this an error?

Thanks in advance.

Regards,
Fernando Figliola

Re: TestSuit Setup

Posted: Mon Aug 13, 2018 1:03 pm
by McTurtle
Hello LicFAF,

Which previous version is it that you are referring to? I don't recall that this would ever work as you described.

Regards,
McTurtle

Re: TestSuit Setup

Posted: Mon Aug 13, 2018 1:52 pm
by LicFAF
Hello McTurtle,
I was woring with Ranorex 7.2.1

Regards,
LicFAF

Re: TestSuit Setup

Posted: Tue Aug 14, 2018 3:53 pm
by McTurtle
Hello LicFAF,

I tried that with Ranorex 7.2.1. Maybe you want to check again. It did not work for me.
The behavior seems to not have changed since Ranorex 7.2.1.
SetupsTest.png
Regards,
McTurtle

Re: TestSuit Setup

Posted: Tue Aug 14, 2018 4:13 pm
by odklizec
Hi,

As far as I know, the test suite-level setup/teardown sections were never performed in case a specific test case is started from command line? We already discussed it in the past...
test suite-level setup/teardown sections were never performed

The recommended solution is using run configuration, in which you can specify the test case(s) you want to run. Specified run configuration (if called from command line), then starts entire test suite with selected test cases (including test suite setup/teardown sections).

Re: TestSuit Setup

Posted: Tue Aug 14, 2018 8:24 pm
by LicFAF
Hi,
First of all thank you for the answers.
Obviously I am wrong, as odklizec says, the way I've solved this isue was using a run configuration.
On the other hand I am sure that this execution worked without a run configuration, maybe there's a user code that performed that task... I'll go back and check everything again.

Thank you very much for your help.

Regards,
LicFAF

Re: TestSuit Setup

Posted: Fri Apr 24, 2020 2:58 pm
by David Zita
Hi,
this is very unfortunate. I have a test suite with over 50 testcases, each completely independent from others. I want to re-run testcase that failed, I am currently creating tool for that, but now I found out the TestSuite Setup and Teardown is not called when running individual TC from command line. That is really showstopper for me :cry: I cannot create 50 test configurations and call the correct one when needed (well I can but it's really unhandy), isn't there any better solution?

Re: TestSuit Setup

Posted: Mon Apr 27, 2020 10:23 am
by foals11
Hi,

I think you can achieve this with the retry count in Ranorex Studio.
Retry count: https://www.ranorex.com/help/latest/ran ... eautoretry

regards,

foals11