I have executed the script and screenshots and all the files are bulk i want to copy all the files and make it as single zip
Hi,
We don’t have much information on OS, whether you need this in RF or not and when…
But you can look a this library:
However this means you have to run robot twice (one for the tests, one for the zip task/process).
Maybe you can use OS tools such as “tar -czvf your_folder.tar.gz”.
Personnaly I use this in my docker container when tests are done to upload results and data’s from execution.
Regards
Charlie
Whats the actual issue here ? You don’t know how to use zip to create an archive or you want to wire somehow to be part of the process or the details @CharlieScene asked for …
For example; if you are using github actions, Upload Artifacts action will do this for you.
Give a path for robot where it should write output files:
python -mrobot \
--outputdir reports/ \
# rest of arguments here
tests/
and then create the zip:
zip yourarchive.zip -r results/*
results should be the same directory that you provided for --outputdir
Worth Noting that this zip archive cannot be written during the test execution because log files are not generated at that point so it has to done after robot exists…