How to run cases from specific folders

Hi!
I have next FOLDER structure:
Preconditions
Folder 2
Folder 3
Negative Cases

I want to run cases in “Preconditions” first, and cases from “Negative Cases” at the end. I’ve created suite-order.txt
It contains:

–suite “Preconditions/”
#WAIT
–suite “Negative Cases/”

But when I try command: pabot --ordering suite-order.txt --processes 8 .
Pabot start to execute all cases not in order from suite-order.txt
What is the problem?

Hi,

Don’t have a direct answer, but would be interested if there’s one.
I have attempted earlier something similar but had issues linked to naming:

Regards.
Charlie

You can try using tags, it may work.

Hi again,

I worked on a another case, and the thing is how you filter your suites between:

  • The suites you eventually give through --suite command in your robot command
  • The folder you use in the robot command (last parameter)
  • And the suites names in the order.txt file

In the file, the structure/name has to fit what robot sees depending of the two first points.

For example if your structure is:
Execdir/FOLDER/Preconditions
And you run in robot from execdir, you might use :
–suite FOLDER.Preconditions in .txt

If your run from ./FOLDER/, in this case it should rather be:
–suite Preconditions

If the structure doesn’t fit, pabot seems to ignore the file and run everything it sees from run folder.

Regards
Charlie

The problem when the suite-order.txt is ignored is usually syntax related in my experience. You could try to look at the generated .pabotsuitenames and try to copy the syntax that is in that file to update your suite-order.txt.

If you have a “correct” suite-order.txt syntax wise, the .pabotsuitenames should not be generated at all, so that could be a check you can do!

Apart from that your syntax with #WAIT should work. You just might have to update the suite lines.

Good luck!