Merge "aggregate-details changed to aggregate-show"

This commit is contained in:
Jenkins 2016-03-25 19:03:50 +00:00 committed by Gerrit Code Review
commit 5f6d731f93
2 changed files with 16 additions and 0 deletions
novaclient
tests/unit/v2
v2

@ -1682,6 +1682,14 @@ class ShellTest(utils.TestCase):
self.run_command('aggregate-details test')
self.assert_called('GET', '/os-aggregates')
def test_aggregate_show_by_id(self):
self.run_command('aggregate-show 1')
self.assert_called('GET', '/os-aggregates/1')
def test_aggregate_show_by_name(self):
self.run_command('aggregate-show test')
self.assert_called('GET', '/os-aggregates')
def test_live_migration(self):
self.run_command('live-migration sample-server hostname')
self.assert_called('POST', '/servers/1234/action',

@ -3803,6 +3803,14 @@ def do_aggregate_remove_host(cs, args):
'aggregate', metavar='<aggregate>',
help=_('Name or ID of aggregate.'))
def do_aggregate_details(cs, args):
"""DEPRECATED, use aggregate-show instead."""
do_aggregate_show(cs, args)
@utils.arg(
'aggregate', metavar='<aggregate>',
help=_('Name or ID of aggregate.'))
def do_aggregate_show(cs, args):
"""Show details of the specified aggregate."""
aggregate = _find_aggregate(cs, args.aggregate)
_print_aggregate_details(aggregate)