Set pool role to Master during unit tests

Make sure pool role is correctly set during startup. Since Context's initial
database is created at module init time, we need to do this even before the
unit test harness can positively set the pool role. We check that this is a
unit test context by checking that the executable's name is not 'xapi'. If it's
not, we assume unit test.

This commit also modifies config_misc to return a default string for the Xen
version if we're running in unit test mode and get an error that we can't
connect to the xc interface.

Signed-off-by: Mike McClurg <mike.mcclurg@citrix.com>
Unit tests can make API calls and persist DB to disk

Suite now initialises xapi's http-svr, http handlers, and domain sockets. The
mock database is set to persist to disk, and can persist between invocations of
make_context_with_new_db (but by default it creates a fresh database each
time). Test case test_ca12350 has been modified to take advantage of these
improvements.

Signed-off-by: Mike McClurg <mike.mcclurg@citrix.com>
Fix test case test_pool_db_backup

This test case was broken by the database changes in the previous commit. After
inspecting the test case, it appears that the test itself was incorrect, and
was passing only because of oddities in the way that the mock database was
constructed. This commit fixes the test case.

Signed-off-by: Mike McClurg <mike.mcclurg@citrix.com>