avocado-framework/avocado — pull request #256 by ruda (2014-11-18 19:13:49+00:00)
Title: Introduce wrap process inside the tests [V1]

Introduce a new command line option `--wrapper` to wrap every new process created with help of module `avocado.utils.process` inside a support script.
The wrappers allows the instrumentation of applications being run by a test in a transparent way and
they can be global, so it will wrap every process or you can set a wrapper to a specific program.

Example of a transparent way of running `strace` as a wrapper::

#!/bin/sh
exec strace -ff -o strace.log -- $@

* Set wrapper to `strace.sh` on each process: `avocado run --wrapper strace.sh sometest`
* Set wrapper only to `strace.sh` and binary `myprog`: `avocado run --wrapper strace.sh:myprog sometest`

You can provide multiples `--wrapper` options in the same command line, but only one global wrapper can be active at time.