From 66f94dca5c524cbe80dfa669cd5422cbb2663fbd Mon Sep 17 00:00:00 2001 From: reedip Date: Fri, 1 Apr 2016 13:48:57 +0900 Subject: Add name option to 'port set' Port's name can be updated in NeutronClient and it is a very good feature for a user to have the ability to rename a port. This was missing in the openstackclient, and the same has been added in this patch. Change-Id: I6e712ef08ab1c0a23786c4bb6972d3e0f8f0f999 Implements: blueprint neutron-client --- openstackclient/tests/network/v2/test_port.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'openstackclient/tests/network') diff --git a/openstackclient/tests/network/v2/test_port.py b/openstackclient/tests/network/v2/test_port.py index cb1af2b8..31454dba 100644 --- a/openstackclient/tests/network/v2/test_port.py +++ b/openstackclient/tests/network/v2/test_port.py @@ -319,6 +319,7 @@ class TestSetPort(TestPort): '--vnic-type', 'macvtap', '--binding-profile', 'foo=bar', '--host', 'binding-host-id-xxxx', + '--name', 'newName', self._port.name, ] verifylist = [ @@ -326,6 +327,7 @@ class TestSetPort(TestPort): ('vnic_type', 'macvtap'), ('binding_profile', {'foo': 'bar'}), ('host', 'binding-host-id-xxxx'), + ('name', 'newName') ] parsed_args = self.check_parser(self.cmd, arglist, verifylist) @@ -336,6 +338,7 @@ class TestSetPort(TestPort): 'binding:vnic_type': 'macvtap', 'binding:profile': {'foo': 'bar'}, 'binding:host_id': 'binding-host-id-xxxx', + 'name': 'newName', } self.network.update_port.assert_called_once_with(self._port, **attrs) self.assertIsNone(result) -- cgit v1.2.1