Running Tests

Basic Operation

Within a test module with a etr.yaml configuration file etr needs no arguments and can be executed like this:

$ etr

Note

Use $ etr --help to get details on command line options.

To run with more information, pass the -v flag, which also can be passed more times for even more verbose output like this:

$ etr -v
$ etr -vv
$ etr -vvv

To execute a test in another directory use the -C flag:

$ etr -C path/to/test/directory

Steps

etr execution is separated into three steps:

  1. setup - Aquisition of test resources. - Process jinja2 template files.
  2. run - Run tests.
  3. teardown - Release test resources.

By default all steps are executed but can also be controlled via the --step option:

# Execute only the setup step
$ etr --step setup

# Execute only the setup and run steps to leave everything running so that run may be
# executed again
$ etr --step setup:run

# Execute tests again
$ etr -step run

Test Subsets

You can specify which tests from etr.yaml to run with the test option:

$ etr --test <test>
$ etr -t <test>

for example:

$ etr -t src/tests.robot

The option may be specified multiple times:

$ etr -t src/tests1.robot -t src/tests2.robot

Cleanup Logs

Run etr clean to cleanup logs, session information and more.

Warning

Take care to release acquired resources before doing this.