Add a plugin for test ordering

Tests in test classes decorated by @ipatests.order_plugin.ordered
are sorted by the source line number instead of alphabetically,
if the plugin is enabled.

The ipa-run-tests helper now loads and enables the plugin.

This should make writing integration tests easier.
Add a framework for integration test configuration

Integration tests are configured via environment variables.
Add a framework for parsing these variables and storing them
in easy-to-use objects.

Add an `ipa-test-config` executable that loads the configuration
and prints out variables needed in shell scripts.

Part of the work for https://fedorahosted.org/freeipa/ticket/3621
Add a framework for integration testing

Add methods to run commands and copy files to Host objects.
Adds a base class for integration tests which can currently install
and uninstall IPA in a "star" topology with per-test specified number
of hosts.
A simple test for user replication between two masters is provided.
Log files from the remote hosts can be marked for collection, but the
actual collection is left to a Nose plugin.

Part of the work for: https://fedorahosted.org/freeipa/ticket/3621
Introduce a class for remote commands

Introduce a class inspired by subprocess.Popen that handles
running a command on a remote machine and handling its output.

To separate stdout & stderr streams of a remote command,
they need to be read in parallel, so that one of them doesn't
stall the runner when its buffer fills up. Accomplish this
by using a thread for each stream.

Part of the work for: https://fedorahosted.org/freeipa/ticket/3621
Collect logs from tests

After each test, and after class setups and teardowns, the BeakerLib
integration plugin now downloads log files from the remote masters
and submits them using rlFileSubmit.

Part of the work for: https://fedorahosted.org/freeipa/ticket/3621
Do not hardcode path to ipa-getkeytab in tests

Using the in-tree binary makes testing outside the source tree
impossible.
Use ipa-getkeytab from $PATH, and add the directory to $PATH when
running the in-tree tests.

Part of the work for https://fedorahosted.org/freeipa/ticket/3654
Show logs in failed tests

Output from IPA's log manager is not captured by Nose's logcapture plugin.
Forward IPA logs to a regular Python logger so that they are shown
on failures.
IPA log messages are also shown on standard error.

Filter out Paramiko logs by default; these are too verbose.

Part of the work for: https://fedorahosted.org/freeipa/ticket/3621
tests: Allow public keys for authentication to the remote machines

Part of the work for https://fedorahosted.org/freeipa/ticket/3621
tests: Configure/unconfigure remote hosts

Set up the hostname, /etc/resolv.conf, and /etc/hosts on remote
hosts in the test setup.
Undo the changes in test teardown.

Part of the work for https://fedorahosted.org/freeipa/ticket/3621
Host class improvements

- Use the external hostname when connecting to remote hosts
- Make it possible to specify working directory for remote commands
- Move kinit calls to installation code
  This allows tests where installation is done later
- Log at error level when a remote command fails unexpectedly
- Clean up test directory before testing
Use dosctrings in BeakerLib phase descriptions

https://fedorahosted.org/freeipa/ticket/3723
BeakerLib plugin: Improve phase names

Phase names are now in the format:
test-module-TestClass-test_method: First line of docstring
BeakerLib plugin: Log http links in test docstrings

The main case for this is having ticket numbers in the Beaker ouput.
Make BeakerLib logging less verbose

Logs from Beaker jobs are normally very brief, with the standard
output/error containing detailed information. Make ipa-run-tests
with BeakerLib plugin follow this convention.

Only include INFO and higher level messages in the Beaker logs.
Downgrade several message levels to DEBUG.
Log to console using Python logging instead of showing the Beaker logs.

Since ipa-run-tests sets up its own logging, Nose's own log
handling just causes duplicate messages. Disable it with --nologcapture.