Command line options¶
This appendix lists all the command line options that are available when executing test cases and when post-processing outputs. Also environment variables affecting execution and post-processing are listed.
Command line options for test execution¶
-
--rpa - Turn on generic automation mode.
-
--language <lang> - Activate localization.
langcan be a name or a code of a built-in language, or a path or a module name of a custom language file. -
-F, --extension <value> - Parse only these files when executing a directory.
-
-I, --parseinclude <pattern> - Parse only matching files when executing a directory.
-
-N, --name <name> - Sets the name of the top-level test suite.
-
-D, --doc <document> - Sets the documentation of the top-level test suite.
-
value> - Sets free metadata for the top level test suite.
-
-G, --settag <tag> - Sets the tag(s) to all executed test cases.
-
-t, --test <name> - Selects the test cases by name.
-
--task <name> - Alias for
--testthat can be used when executing tasks. -
-s, --suite <name> - Selects the test suites by name.
-
-R, --rerunfailed <file> - Selects failed tests from an earlier output file to be re-executed.
-
-S, --rerunfailedsuites <file> - Selects failed test suites from an earlier output file to be re-executed.
-
-i, --include <tag> - Selects the test cases by tag.
-
-e, --exclude <tag> - Selects the test cases by tag.
-
--skip <tag> - Tests having given tag will be skipped. Tag can be a pattern.
-
--skiponfailure <tag> - Tests having given tag will be skipped if they fail.
-
value> - Sets individual variables.
-
args> - Sets variables using variable files.
-
-d, --outputdir <dir> - Defines where to create result files.
-
-o, --output <file> - Sets the path to the generated output file.
-
--legacyoutput - Creates output file in Robot Framework 6.x compatible format.
-
-l, --log <file> - Sets the path to the generated log file.
-
-r, --report <file> - Sets the path to the generated report file.
-
-x, --xunit <file> - Sets the path to the generated xUnit compatible result file.
-
-b, --debugfile <file> - A debug file that is written during execution.
-
-T, --timestampoutputs - Adds a timestamp to result files listed above.
-
--splitlog - Split log file into smaller pieces that open in browser transparently.
-
--logtitle <title> - Sets a title for the generated test log.
-
--reporttitle <title> - Sets a title for the generated test report.
-
--reportbackground <colors> - Sets background colors of the generated report.
-
--maxerrorlines <lines> - Sets the number of error lines shown in report when tests fail.
-
--maxassignlength <characters> - Sets the number of characters shown in log when variables are assigned.
-
-L, --loglevel <level> - Sets the threshold level for logging. Optionally the default visible log level can be given separated with a colon (:).
-
--suitestatlevel <level> - Defines how many levels to show in the Statistics by Suite table in outputs.
-
--tagstatinclude <tag> - Includes only these tags in the Statistics by Tag table.
-
--tagstatexclude <tag> - Excludes these tags from the Statistics by Tag table.
-
title> - Creates combined statistics based on tags.
-
doc> - Adds documentation to the specified tags.
--tagstatlink <pattern:link:title>- Adds external links to the Statistics by Tag table.
--expandkeywords <name:pattern|tag:pattern>- Automatically expand keywords in the generated log file.
--removekeywords <all|passed|name:pattern|tag:pattern|for|while|wuks>- Removes keyword data from the generated log file.
--flattenkeywords <for|while|iteration|name:pattern|tag:pattern>- Flattens keywords in the generated log file.
-
args> - Sets a listener for monitoring test execution.
-
--nostatusrc - Sets the return code to zero regardless of failures in test cases. Error codes are returned normally.
-
--runemptysuite - Executes tests also if the selected test suites are empty.
-
--dryrun - In the dry run mode tests are run without executing keywords originating from test libraries. Useful for validating test data syntax.
-
-X, --exitonfailure - Stops test execution if any test fails.
-
--exitonerror - Stops test execution if any error occurs when parsing test data, importing libraries, and so on.
-
--skipteardownonexit - Skips teardowns if test execution is prematurely stopped.
-
args> - Activate programmatic modification of test data.
-
args> - Activate programmatic modification of results.
--randomize <all|suites|tests|none>- Randomizes test execution order.
--console <verbose|dotted|quiet|none|custom>- Console output type. Also accepts custom console loggers.
-
--dotted - Shortcut for
--console dotted. -
--quiet - Shortcut for
--console quiet. -
-W, --consolewidth <width> - Sets the width of the console output.
-C, --consolecolors <auto|on|ansi|off>- Specifies are colors used on the console.
--consolelinks <auto|off>- Controls making paths to results files hyperlinks.
-K, --consolemarkers <auto|on|off>- Show markers on the console when top level keywords in a test case end.
-
-P, --pythonpath <path> - Additional locations to add to the module search path.
-
-A, --argumentfile <path> - A text file to read more arguments from.
-
-h, --help - Prints usage instructions.
-
--version - Prints the version information.
Command line options for post-processing outputs¶
-
--rpa - Turn on generic automation mode.
-
-R, --merge - Changes result combining behavior to merging.
-
-N, --name <name> - Sets the name of the top level test suite.
-
-D, --doc <document> - Sets the documentation of the top-level test suite.
-
value> - Sets free metadata for the top-level test suite.
-
-G, --settag <tag> - Sets the tag(s) to all processed test cases.
-
-t, --test <name> - Selects the test cases by name.
-
--task <name> - Alias for
--test. -
-s, --suite <name> - Selects the test suites by name.
-
-i, --include <tag> - Selects the test cases by tag.
-
-e, --exclude <tag> - Selects the test cases by tag.
-
-d, --outputdir <dir> - Defines where to create result files.
-
-o, --output <file> - Sets the path to the generated output file.
-
--legacyoutput - Creates output file in Robot Framework 6.x compatible format.
-
-l, --log <file> - Sets the path to the generated log file.
-
-r, --report <file> - Sets the path to the generated report file.
-
-x, --xunit <file> - Sets the path to the generated xUnit compatible result file.
-
-T, --timestampoutputs - Adds a timestamp to result files listed above.
-
--splitlog - Split log file into smaller pieces that open in browser transparently.
-
--logtitle <title> - Sets a title for the generated test log.
-
--reporttitle <title> - Sets a title for the generated test report.
-
--reportbackground <colors> - Sets background colors of the generated report.
-
-L, --loglevel <level> - Sets the threshold level to select log messages. Optionally the default visible log level can be given separated with a colon (:).
-
--suitestatlevel <level> - Defines how many levels to show in the Statistics by Suite table in outputs.
-
--tagstatinclude <tag> - Includes only these tags in the Statistics by Tag table.
-
--tagstatexclude <tag> - Excludes these tags from the Statistics by Tag table.
-
title> - Creates combined statistics based on tags.
-
doc> - Adds documentation to the specified tags.
--tagstatlink <pattern:link:title>- Adds external links to the Statistics by Tag table.
--expandkeywords <name:pattern|tag:pattern>- Automatically expand keywords in the generated log file.
--removekeywords <all|passed|name:pattern|tag:pattern|for|wuks>- Removes keyword data from the generated outputs.
--flattenkeywords <for|foritem|name:pattern|tag:pattern>- Flattens keywords in the generated outputs.
-
--starttime <timestamp> - Sets the starting time of test execution when creating reports.
-
--endtime <timestamp> - Sets the ending time of test execution when creating reports.
-
--nostatusrc - Sets the return code to zero regardless of failures in test cases. Error codes are returned normally.
-
--processemptysuite - Processes output files even if files contain empty test suites.
-
args> - Activate programmatic modification of results.
--console <verbose|quiet|none|custom>- Controlling Rebot console output. Also accepts custom console loggers.
-
--quiet - Shortcut for
--console quiet. -C, --consolecolors <auto|on|ansi|off>- Specifies are colors used on the console.
--consolelinks <auto|off>- Controls making paths to results files hyperlinks.
-
-P, --pythonpath <path> - Additional locations to add to the module search path.
-
-A, --argumentfile <path> - A text file to read more arguments from.
-
-h, --help - Prints usage instructions.
-
--version - Prints the version information.
Environment variables for execution and post-processing¶
-
ROBOT_OPTIONSandREBOT_OPTIONS - Space separated list of default options to be placed
in front of any explicit options on the command line.
-
ROBOT_SYSLOG_FILE - Path to a syslog file where Robot Framework writes internal
information about parsing test case files and running
tests.
-
ROBOT_SYSLOG_LEVEL - Log level to use when writing to the syslog file.
-
ROBOT_INTERNAL_TRACES - When set to any non-empty value, Robot Framework's
internal methods are included in error tracebacks.