avocado.result: Introduce TestResultProxy

Create a class that has the same interface as a
test result, but in fact has a list of test result
objects and can write to each of them any time
a test result operation is called. This is the
first step to make multiple output plugins to
work.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado: Make it possible to use multiple output plugins

Set up the TestResultProxy for the Job object, and
populate the test result objects according to what
the currently active plugins set. This means we go
on finding arguments with the suffix _result and
selecting any values that are classes derived from
TestResult and appending them to the result proxy.

With this, we can use any number of test result
plugins we'd like. If no test result objects are
set by plugins, fall back to the human output plugin.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado: Change output plugins to have extra 'output' and 'output_option' attr

In order to be able to tell whether there's more than one
output plugin trying to use the stdout, add the 'output'
and 'output_option' attributes. This changes the current
output plugins to use and set these attributes correctly.

Fix the xunit unittest to take into account the new
attribute names.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado.job: Prevent 2 output plugins to output to the stdout at the same time

With the new attributes, change the output setup procedure
to verify if more than one output plugin wants to use the
stdout, in which case we print an error message and fail.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
selftests/functional: Add output plugins testing

It's necessary if we're generating valid outputs in
the appropriate places, and that they respect the
rules established so far.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado.job: Always add JSON and Xunit outputs to job dir

As specified in the requirements meeting, always have Xunit and
JSON outputs written to the results dir. The basic idea is to
enable any output plugins specified in the cmd line, the Xunit
and JSON compulsorily, and in the end, if there are no output
plugins requested in the command line, enable human output.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
selftests/functional: Add tests for the always on output plugins

Add extra tests that verify that the always on output
plugins (JSON and Xunit inside the debug dir) are being
correctly generated and the outputs are valid.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
selftests/functional: Add journal plugin to the compatible output test

As I realized we did not have the journal plugin out here.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado.plugins.vm: Add missing name attribute to the test vm attribute

As it was missing, causing an error with the json output.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
avocado.plugins.vm: Add the other missing important attributes of the Test class

This way, tests in vm that fail won't trigger a problem
on XML outputs and crash avocado.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
docs: Update Output Plugins documentation

Some brief documentation on the JSON output plugin and
multiple output plugins.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>