Parallel execution of test cases from Test suite is available in Katalon?

I want to execute the test cases present in my test suite parallelly. All the test cases are mutually independent on each other. Kindly let me know if Katalon has this feature. I am using the licensed version of the Katalon studio.

2 Likes

No, you can’t.

1 Like

It’s a Frequently Asked Quetion. You can find a lot of previous posts about the same issue. For example,

1 Like

@Katalon_CS, this is the basic feature automation team needs. I am really not sure why Katalon did not implement this.

1 Like

Please ask Katalon people

@Elly_Tran @vu.tran

IMHO, parallel test execution can be talked about casually but quite hard to implement.

1 Like

The following seems to be the only feasible option of parallel execution in Katalon products

Play nice family. Not worth getting worked up for.
As it relates to the OP @siddesh.kumarbs and both of you guys too…
@bionel and @Brandon_Hein - Send me an email Mike.Verinder@katalon.com
Tell me your North Star version of how you would like this to work in the future.

and I’ll do some vetting and extended chats with the product team to see where we can take this (and in what timeframe)

1 Like

I’ll just post it here so that OP can see/comment.

I would expect to be able to toggle on “parallel mode” at the suite level, then set the number of concurrent tests to run. On most modern machines, and depending on the resource-intensity of the actual test cases, a safe rule of thumb is to limit the number of threads to be equal to or less than the number of cores on your machine but usually you’ll have to set it lower. For example, on my 8-core mac, I generally run 4 threads without issue. You will not get a linear increase in performance, but it should be overall faster than running the same tests sequentially.

Again, I’m sure this was already considered by the dev team, so maybe they can comment on why they decided not to go this route.

A few years ago, I have done a experiment where a Test Case creates multiple Java Threads to execute other test cases: one test case per thread.

In short, this experiment gave me a total mess. It was not useful at all.

  1. The test didn’t run fast at all. It ran far slower than a sequential (well-ordered) execution of Test Cases.
  2. Every single test case required a Chrome browser instance to launch. This resulted serious resource contentions on my single poorly equipped PC.If I ran 10 thread, then 10 browser processes need to be launched. But actually they weren’t. Every Chrome demanded the TCP connection to the internet. But my home wifi was not broad enough to accomondate 10 TC sessions to work symultaneously. Even I found the Chrome itself seems controlling the number of child processes on a single PC — I could not see the myth how Chrome controls the suprocesses internally.
  3. I saw 10 threads were activated and were just queued on the Thread-pool; executed only one-by-one due to resource contention.
  4. What happens when a single Test Case failed? Is it possible to provide a good report what happened in which code, and tell us how to fix it? ---- It was very difficult.
  5. The execution log of parallel 10 Threads was just a mess. It was so difficult that I could not manage to compile a readable execution reports of 10 Threads.

I will review your project. I’m not sure how difficult it is in the current implementation of Katalon specifically to make this work effectively. I leave that to the Katalon devs to determine.

I do know that it’s perfectly possible to do with a custom tech stack (TestNG, Selenium, Selenium Grid), because our team is using it to great effect (in combination with distributed systems in some cases).

TestNG is specifically designed to solve the problem listed in your project, i.e.

" I know that Katalon Studio offers a feature of executing Test Suites in parallel mode. It isn’t satisfactory for me. It is too coarse-grained. I want a way to execute a piece of Groovy scripts in fine-grained / light-weighted Java Threads."

In TestNG, you can define which “layer” to run in parallel, i.e. Test suite, test case, or test method. I’m not sure of a way to emulate this in the current iteration of Katalon.

Thank you, but no, I am not interested in this issue any longer.

I don’t know TestNG at all, but I guess TestNG is developed with parallelism in mind. It’s great. I believe that a successful testing parallelism requires a dedicated design of the UI testing tools; Katalon is not well designed for it. So, if someone seriously wants any parallelism for faster execution of her/his tests, I suppose she/he should look for other UI testing tools.

testng is yet another testing framework.
dont do any magic.
java based, the mentioned layers are just threads.
there may be some certain thread isolation but here is where the magic ends.
thats all.
the same you can achieve by gradle or maven clever use with plain java or groovy.
and yeah, i used such a bit.
is just a junit rewrite, with some clever annotations.

if i have to compare with anything else, pytest is by an order of magnitude better.
but here we speak about a full test environment (katalon), not about frameworks.
therefore, some may have missed the point

The lesson I learned was simple. If I want 4 tests to run in real parallel I would need 4 machines on a fast enough network.

The only question is how I can distribute the 4 tests onto the nodes and how I can consolidate the execution results once they finished. A single MacBook on a poor home WiFi is not enough. I woud need some Cloud service (aws, azure, gcp, etc) to build a real system. But I am not interested in this theme now.

1 Like

Hi folks, :wave:

Looks like things got a little “heated” a while ago between some members in this thread. Hence, we will proceed to close this thread soon to prevent further “beef” between them.

In the meantime, as @siddesh.kumarbs has mentioned that you are using a licensed version of Katalon, I presume that you are one of our paid customers. If that is the case, then you could log into our Support Portal (link below) for more dedicated support.

https://katalon-inc.my.site.com/katalonhelpcenter/s/

Or, you could open up another thread/Personal Message with our Product Support team (@support.squad) if you prefer communicating with them via our forum.

Thanks :+1:

This topic was automatically closed after 16 hours. New replies are no longer allowed.