Fix cluster-policy-list command
After switching to SDK calls, we are not properly showing the name and type of policies bound to a cluster. This patch fixes the problem. Change-Id: Ie5549ba6c8c67943c0595469d9fc1d7094e6825b
This commit is contained in:
@@ -944,8 +944,8 @@ class ShellTest(testtools.TestCase):
|
||||
|
||||
@mock.patch.object(utils, 'print_list')
|
||||
def test_do_cluster_policy_list(self, mock_print):
|
||||
fields = ['policy_id', 'policy', 'type', 'priority', 'level',
|
||||
'cooldown', 'enabled']
|
||||
fields = ['policy_id', 'policy_name', 'policy_type', 'priority',
|
||||
'level', 'cooldown', 'enabled']
|
||||
service = mock.Mock()
|
||||
args = {
|
||||
'id': 'C1',
|
||||
|
||||
@@ -716,7 +716,7 @@ def do_cluster_scale_in(service, args):
|
||||
help=_('Name or ID of cluster to query on.'))
|
||||
def do_cluster_policy_list(service, args):
|
||||
"""List policies from cluster."""
|
||||
fields = ['policy_id', 'policy', 'type', 'priority', 'level',
|
||||
fields = ['policy_id', 'policy_name', 'policy_type', 'priority', 'level',
|
||||
'cooldown', 'enabled']
|
||||
sort_keys = ['priority', 'level', 'cooldown', 'enabled']
|
||||
|
||||
|
||||
Reference in New Issue
Block a user