I have executed a data-driven (5) scenario with Pabot in parallel. I would like to execute after all once suite teardown for merging custom Excel files. But, unfortunately suite teardown works for each scenario like test teardown. How can I handle that?
Thanks in advance!
I have find the solution, pls check the https://pabot.org/PabotLib.html#valuetransfer
Suite Teardown Run Teardown Only Once Merge Parallel Excel Reports
pabotlib has “Run Only Once” … Havent used it but if you have suite teardown on all of your suites, that teardown has is executed only once after all the suites are done if the docs are correct.
However, as im writing this - for the past week ive been tackling exactly the same sort of issue; i have N amount of testsuites that should generate single excel file.
I run pabot.pabot.main_program() with correct arguments – after that, all my temporary “excel” files are in single output directory and then i run separate robot task suite with robot.run() to combine the files in the output directory of the pabot run…
All the “code” is still robot - only thing different with this sort of approach is that instead of running pabot or robot command, i run a python script that coordinates all of above steps in correct order with correct cli arguments…
Thanks for info, this run only keyword work effective. You can try it, i have handle with this one.