Ability to have a Suite (Collection) Set Up and Tear Down just like a Test Case Set Up / Teardown

Being used to work with the Fitnesse Test Framework, I think it would be great if Katalon Studio provides the ability to have Set Up and Tear Down methods on Test Suite and Test Suite Collection level, just like the setup / Teardown methods for a test case.

This will make it possible to define a Set Up and Tear down method for a specific Test Suite / Test Suite Collection, so that Test Suite A can have a different Set Up than Test Suite B (The same for Test Suite Collections).
This is different from the Test Listeners, because these apply to every Test Suite / Test Case (Correct me if I’m wrong).

This would make it also very easy to run tests against different test enviroments. Just make a Test Suite Collection for every test enviroment (containing the same test suites) and define in the Set Up of the Test Suite Collection the specific environment variables as Global variables such as URL, accounts, etc.

2 Likes

Lukas,

Great suggestion! Actually, We just added Set Up/Teardown for Test Suite Level in the next release of Katalon Studio. Stay close!

Thanks for your suggestion to make Katalon Studio better!

Liam

Hi Liam,

Is it also possible to implement Set Up/Teardown at Test Suite Collection Level?

I guess if we could link Test Listeners to a specific Test Suite or Test Suite Collection, you could achieve the same thing . Make a Test Listener that only applies for a specfic Test Suite (Collection) or a collection of Test Suites / Test Suite Collections.

But than you also have to have Test Listeners at Test Suite Collection Level and at the moment these are missing.
With regards,

Lukas

Hi Lukas,

Would you please provide more details on why you need SU/TD at Test Suite Collection Level?
I will need your information for evaluating and present to the team.

Best,

Liam

Hi Liam,

Suppose I have a Test Suites collection that contains Test Suites for a certain test environment.

Now a want to run this Test Suite Collection against a different test environment.

Having a SU/TD at Test Suite Collection Level will make this super easy.

I just make a copy of the Test Suite Collection. Create a different setup, in which I set the correct Global Variables, for each Test Suite Collection and I’m done.

An another example. Suppose I have one Test Suite Collection which contains all my Web UI tests and have another Test Suite Collection that contains my API tests.

For each I need a global setup which contains some code to initialize the environment, the URL’s, accounts, APi key. With a SU/TD at Test Suite Collection level this can be easly done.

I guess it’s just I’m used to working with Fitnesse in which you can do the following:

SuiteLevel_1

: |–SuiteSetUp

|--SuiteTearDown 

|--SetUp 

|--TearDown   
|--TestCase001  

`--SuiteLevel_2.1 

    |--SuiteSetUp 

    |--SuiteTearDown 

    |--SetUp 

    |--TearDown 

    |--TestCase001

    |--TestCase002 

    |--TestCase003 

`–SuiteLevel_2.2

    |--SuiteSetUp 

    |--SuiteTearDown 

    |--SetUp 

    |--TearDown 

    |--TestCase001

    |--TestCase002 

You can nest Test Suites.

Every Test Suite can have it’s own SuiteSetUp and SuiteTeardown and a SetUp/TearDown that get’s executed for every Test Case in the Suite.

When you run SuiteLevel_1 also the suites SuiteLevel_2.1 and SuiteLevel_2.2 gets executed.

Hey Lukas,

Thanks for the information. I will discuss with the team to see what we can do. Let us know if you have any further concerns.

Best,
Liam

@Liam_B Is there any update on this? I have another scenario. When integrated with TestRail, it is updates results after every test suite. It collects all the test cases in a that test run and update the result for only those test cases in that test suite. But I want this to be done at test suite collection level so that test case results will be updated at once after test suite collection.

1 Like