Katalon Test Step Execution

Hello , @devalex88 @ThanhTo

For Katalon Studio test steps, for example, if the test is in step 5, can it be routed to step 1? So we can continue the test from any line in a Test Case? Is there such a referral ?

Thank You …

Hi @emine

It is not possible to do this at the present. I highly recommend designing your test cases in a modular way so that they can be called from other test cases. With that you can achieve reusing test steps in a less micro approach than what you’re asking for.

Just for reference, if you’re interested, what you’re asking is basically the equivalence of goto statement in programming which is considered harmful.

1 Like

hello @ThanhTo

Thank you very much for your answer. I wondered if this was the case.
As you said, I do this by creating small step test cases and calling them in the relevant test steps.
Thank you very much again …

1 Like

bad goto … very bad.
i remember it from the era when i did basic-s programing.
took me a lot to get rid of such thinking when i jumped to procedural / functional aproach … but in the end i managed to re-organize my brain.


Just my 2 cents…

There’s nothing wrong with goto that can’t be cured by better trained programmers. (Me, c.1985)

1 Like

Hello Again @Russ_Thomas
I already do this with the Katalon Studio’s Call Test Case keyword. I was just wondering if there is such a special keyword.
Thanks everyone.

Hello @Ibus
My coding is pretty good. I can do this with Katalon Studio Call Test Case. I just wanted to ask if there is a specific specific keyword specific to the situation I’ve specified.

I’m not sure what you’re asking me.

But to your original question:

One of the “benefits” of goto on some systems was that it came with a counterpart called “label”. You could goto :mylabel, for example. I think you’re asking for something similar in Groovy?

Well, there are such things as continue label and break label but they’re not going to give you what you’re asking for (a way to jump into the middle of another test case).

Aside: Even today, under the covers, all processor instruction sets support a notional goto statement in their Jump or JP instructions. They load the PC/IP (program counter/instruction pointer) with a new memory address and proceed from there.

More goto links: https://duckduckgo.com/?q=groovy+goto+label&t=ffab&ia=web

1 Like

@emine one of the nightmares i recently had was few years ago when i started to use postman.
to create decisional workflow … guess what. exactly goto approach, via postman.setNextRequest().
all was fine … until you get in a continuous loop, because sometime you have to edit a certain request, so his id has changed so the iteration won’t find anymore the ‘exit condition’ :slight_smile: or … it wont find the switch condition so instead to bypass the not-needed cases will execute them in order.
so … if you can avoid such design, my advise is to do it. use it only when you have no other option … but with caution. is very hard to maintain such code in a sane manner!


hello All , @Ibus and @Russ_Thomas
Thank you so much …

@emine you are welcomed!
we are here to share our knowledge. and sometime we learn from our mistakes :slight_smile: