From 9c91c1df4147cbd277c3384b0c648a6069c5f723 Mon Sep 17 00:00:00 2001 From: Tang Chen Date: Wed, 17 Feb 2016 14:39:57 +0800 Subject: Make SetAgent inherit from cliff.Command set/unset command classes should inherit from cliff.Command class. Also, this patch adds functional tests for compute agent. Change-Id: I25eafffd1167f82aa0d430628c22dee7516b1e19 Partial-Bug: 1546065 --- openstackclient/compute/v2/agent.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'openstackclient') diff --git a/openstackclient/compute/v2/agent.py b/openstackclient/compute/v2/agent.py index 59d7dc66..d5e86033 100644 --- a/openstackclient/compute/v2/agent.py +++ b/openstackclient/compute/v2/agent.py @@ -112,7 +112,7 @@ class ListAgent(command.Lister): ) for s in data)) -class SetAgent(command.ShowOne): +class SetAgent(command.Command): """Set compute agent command""" def get_parser(self, prog_name): @@ -143,5 +143,4 @@ class SetAgent(command.ShowOne): parsed_args.url, parsed_args.md5hash ) - agent = compute_client.agents.update(*args)._info.copy() - return zip(*sorted(six.iteritems(agent))) + compute_client.agents.update(*args) -- cgit v1.2.1