Revision: 731e55872843
Branch:   default
Author:   Pekka Klärck
Date:     Thu Nov  7 13:51:45 2013 UTC
Log:      Documented ROBOT_OPTIONS and REBOT_OPTIONS

Update issue 1566
Status: Done
Documentation added both to --help texts and to User Guide.
http://code.google.com/p/robotframework/source/detail?r=731e55872843

Modified:
 /doc/userguide/src/ExecutingTestCases/BasicUsage.rst
 /src/robot/rebot.py
 /src/robot/run.py

=======================================
--- /doc/userguide/src/ExecutingTestCases/BasicUsage.rst Wed Oct 9 13:10:58 2013 UTC +++ /doc/userguide/src/ExecutingTestCases/BasicUsage.rst Thu Nov 7 13:51:45 2013 UTC
@@ -140,6 +140,29 @@
 :cli:`--include a???` matches any tag that is four characters long and
 starts with a character :code:`a`.

+:var:`ROBOT_OPTIONS` and :var:`REBOT_OPTIONS` environment variables
+'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
+
+Environment variables :var:`ROBOT_OPTIONS` and :var:`REBOT_OPTIONS` can be
+used to specify default options for `test execution`_ and `result
+post-processing`__, respectively. The options and their values must be
+defined as a space separated list and they are placed in front of any
+explicit options on the command line. The main use case for these
+environment variables is setting global default values for certain options to +avoid the need to repeat them every time tests are run or :prog:`rebot` used.
+
+.. sourcecode:: bash
+
+   export ROBOT_OPTIONS="--critical regression --tagdoc mytag:Example_doc"
+   pybot tests.txt
+   export REBOT_OPTIONS="--reportbackground green:yellow:red"
+   rebot --name example output.xml
+
+.. note:: Support for :var:`ROBOT_OPTIONS` and :var:`REBOT_OPTIONS` environment
+          variables was added in Robot Framework 2.8.2.
+
+__ `Post-processing outputs`_
+
 Test results
 ~~~~~~~~~~~~

=======================================
--- /src/robot/rebot.py Wed Nov  6 12:38:04 2013 UTC
+++ /src/robot/rebot.py Thu Nov  7 13:51:45 2013 UTC
@@ -263,6 +263,8 @@
 Environment Variables
 =====================

+REBOT_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 file where Robot Framework writes internal information about processed files. Can be useful when
                           debugging problems. If not set, or set to special
=======================================
--- /src/robot/run.py   Wed Nov  6 12:38:04 2013 UTC
+++ /src/robot/run.py   Thu Nov  7 13:51:45 2013 UTC
@@ -332,6 +332,8 @@
 Environment Variables
 =====================

+ROBOT_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 file where Robot Framework writes internal information about parsing test case files and running tests. Can be useful when debugging problems. If not
@@ -359,7 +361,8 @@
# Executing multiple test case files and using case-insensitive long options.
 $ pybot --SuiteStatLevel 2 /my/tests/*.html /your/tests.html

-# Setting syslog file before running tests.
+# Setting default options and syslog file before running tests.
+$ export ROBOT_OPTIONS="--critical regression --suitestatlevel 2"
 $ export ROBOT_SYSLOG_FILE=/tmp/syslog.txt
 $ pybot tests.tsv
 """

--

--- You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to