Unfortunately that's not possible. The current output splitting logic
is already so complicated that adding more features into it would be
pretty hard. We have, in fact, been thinking about simplifying it a
little some time in the future.
Cheers,
.peke
--
Agile Tester/Developer/Consultant :: http://eliga.fi
Lead Developer of Robot Framework :: http://robotframework.org
I found a way to direct output to folders. It is a little complex but possible. For those interested I provide the following info with code.
We can store the test suites as they are run with full path in a text file in the order in which they were executed using ${SUITESOURCE}. We sort this file using a python program which looks at the length of the array with respect to split operation on these suite paths using '\\'.
We exchange 2 elements in the file if a path of length which is lower occurs later (below). We then use a recursive function call to the sort function to ensure that no path with higher length occurs later. This order of the newly sorted suite paths file it turns out is the same as what we can do using splitoutputs with rebot at each tree level.
Whatever output and log files are generated from splitoutputs using rebot we sort alphabetically and move to the sorted suite file path dirs which are created in a separate test results folder now in that order.
Please find attached the several files used for running this operation.
Thanks & Regards,
Rajaraman.
________________________________
Regards,
Rajaraman.
-----Original Message-----
From: Rajaraman Swaminathan
Sent: Monday, November 29, 2010 9:58 AM
To: 'Pekka Klärck'
Cc: robotframework-users; Sudip Naha
Subject: RE: Directing output logs to folders
Hi,
I found a way to direct output to folders. It is a little complex but possible. For those interested I provide the following info with code.
We can store the test suites as they are run with full path in a text file in the order in which they were executed using ${SUITESOURCE}. We sort this file using a python program which looks at the length of the array with respect to split operation on these suite paths using '\\'.
We exchange 2 elements in the file if a path of length which is lower occurs later (below). We then use a recursive function call to the sort function to ensure that no path with higher length occurs later. This order of the newly sorted suite paths file it turns out is the same as what we can do using splitoutputs with rebot at each tree level.
Whatever output and log files are generated from splitoutputs using rebot we sort alphabetically and move to the sorted suite file path dirs which are created in a separate test results folder now in that order.
Please find attached the several files used for running this operation.
Thanks & Regards,
Rajaraman.
-----Original Message-----
From: pekka....@gmail.com [mailto:pekka....@gmail.com] On Behalf Of Pekka Klärck
Sent: Sunday, November 28, 2010 8:25 PM
To: Rajaraman Swaminathan
Cc: robotframework-users; Sudip Naha
Subject: Re: Directing output logs to folders
________________________________
By default processes are run so that their standard output and standard error streams are kept in the memory. This works fine normally, but if there is a lot of output, the output buffers may get full and the program can hang. Additionally on Jython, everything written to these in-memory buffers can be lost if the process is terminated.
To avoid the above mentioned problems, it is possible to use stdout and stderr arguments to specify files on the file system where to redirect the outputs. This can also be useful if other processes or other keywords need to read or manipulate the outputs somehow.
Given stdout and stderr paths are relative to the current working directory. Forward slashes in the given paths are automatically converted to backslashes on Windows.
As a special feature, it is possible to redirect the standard error to the standard output by using stderr=STDOUT.
Regardless are outputs redirected to files or not, they are accessible through the result object returned when the process ends.
Examples:
${result} = | Run Process | program | stdout=${TEMPDIR}/stdout.txt | stderr=${TEMPDIR}/stderr.txt |
Log Many | stdout: ${result.stdout} | stderr: ${result.stderr} | ||
${result} = | Run Process | program | stderr=STDOUT | |
Log | all output: ${result.stdout} |
Note that the created output files are not automatically removed after the test run. The user is responsible to remove them if needed.
I am not sure where and how I can specify my folder hierarchy using these keywords. I am open to using other options that would serve this purpose too.
Thank you,