Align mocking pattern for test case

Mock sys.stderr/sys.stdout with mock.patch()

In novaclient/tests/test_shell.py, ShellTest.shell(), it is another
case that should be aligned. But it may induce test error if changed.
So, let's keep it as is.

Close-Bug #1237093

Change-Id: I8908dc1593dbbbaf2813cc8fb034be32972140a0
Updated from global requirements

Change-Id: I2cc2769b89bd040064408faea30c448350fa5f00
Apply six for metaclass

The way to using metaclass has changed in Python3.

Python 2.7 way:

class Foo(object):
  __metaclass__ = FooMeta

Python 3 way:

class Foo(object, metaclass=FooMeta):
  ...

The six.add_metaclass() decorator allows us to use one syntax that
works for both Python 2.7 and Python 3.

Change-Id: Ibd31a9f91bac6ec220d802f16c77ee0306e211b3
Closes-Bug: #1236648
Add --insecure to curl output if required

Change-Id: I5762f6659a6687b86c94a6e371ccc7509d1e26f9
Quote URL in curl output to handle query params

Copy and pasting the generated curl output into a shell doesn't
work when the URL includes an ampersand, as the URL isn't quoted.

This simplifies the logic in client.http_log_req to be able to
output the URL and method separately and quote the URL.

Change-Id: I1e497886ea9334771ab91e657e7c1121d89f7f33
Make 'nova ssh' automatically fall back to private address

If no public IP address is available automatically revert to the private address.

Change-Id: Iaf780fde77c4a1eae99c27be7e21841ca87d69dc
Nova aggregate-details should be more human friendly

'nova aggregate-details' shows Hosts, Availability Zone
and Metadata in the python unicode notation.

Change-Id: If0028347146439994265c60c429af05dd67912f9
Closes-Bug: #1132961
Merge "Align mocking pattern for test case"
Merge "Add --insecure to curl output if required"
Merge "Quote URL in curl output to handle query params"
Merge "Nova aggregate-details should be more human friendly"
Adds locking to completion caches

Previously, completion caches were not thread-safe and multiple
threads could not make calls to python-novaclient simultaneously.
With locking, the completion caches are now thread-safe.

Closes-Bug: #1213958
Change-Id: I201c2ed0f1eb09b1c2a74de96119cbae9ed6f4b0
Update mailmap for Joe Gordon

Update mailmap to reflect that I am committing from a new email address.

Change-Id: Ibf03482768a639c4c2fe57fca045daaab0233688
Revert "Nova aggregate-details should be more human friendly"

This reverts commit 6374ee04a378b8a970f9e429d66eb37c969bbf7b.

Change-Id: Ib27cc6722ea7cc8cb9b133360b3ecb246a0e4a14
Merge "Update mailmap for Joe Gordon"
Merge "Adds locking to completion caches"
Added trace header forwarding
Added trace header option
Added general request tracing