From f50bd408666df161603f9ce20a5d00428a13b2ef Mon Sep 17 00:00:00 2001 From: pedh <hcn518@gmail.com> Date: Tue, 18 Aug 2020 20:28:27 +0800 Subject: [PATCH] Fix: port attribute name propagate_uplink_status Change the incorrect port attribute name "uplink_status_propagation" to "propagate_uplink_status". Change-Id: Icd7c49af8d988a6e3a52a58c784bd701b2d36faf Closes-Bug: #1891873 --- openstackclient/tests/unit/network/v2/fakes.py | 6 +++--- openstackclient/tests/unit/network/v2/test_port.py | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/openstackclient/tests/unit/network/v2/fakes.py b/openstackclient/tests/unit/network/v2/fakes.py index 3df4042cba..74001375a4 100644 --- a/openstackclient/tests/unit/network/v2/fakes.py +++ b/openstackclient/tests/unit/network/v2/fakes.py @@ -642,7 +642,7 @@ class FakePort(object): 'qos_network_policy_id': 'qos-policy-id-' + uuid.uuid4().hex, 'qos_policy_id': 'qos-policy-id-' + uuid.uuid4().hex, 'tags': [], - 'uplink_status_propagation': False, + 'propagate_uplink_status': False, } # Overwrite default attributes. @@ -662,8 +662,8 @@ class FakePort(object): port.project_id = port_attrs['tenant_id'] port.security_group_ids = port_attrs['security_group_ids'] port.qos_policy_id = port_attrs['qos_policy_id'] - port.uplink_status_propagation = port_attrs[ - 'uplink_status_propagation'] + port.propagate_uplink_status = port_attrs[ + 'propagate_uplink_status'] return port diff --git a/openstackclient/tests/unit/network/v2/test_port.py b/openstackclient/tests/unit/network/v2/test_port.py index f729b552ff..d8889ae558 100644 --- a/openstackclient/tests/unit/network/v2/test_port.py +++ b/openstackclient/tests/unit/network/v2/test_port.py @@ -62,12 +62,12 @@ class TestPort(network_fakes.TestNetworkV2): 'numa_affinity_policy', 'port_security_enabled', 'project_id', + 'propagate_uplink_status', 'qos_network_policy_id', 'qos_policy_id', 'security_group_ids', 'status', 'tags', - 'uplink_status_propagation', ) data = ( @@ -94,12 +94,12 @@ class TestPort(network_fakes.TestNetworkV2): fake_port.numa_affinity_policy, fake_port.port_security_enabled, fake_port.project_id, + fake_port.propagate_uplink_status, fake_port.qos_network_policy_id, fake_port.qos_policy_id, format_columns.ListColumn(fake_port.security_group_ids), fake_port.status, format_columns.ListColumn(fake_port.tags), - fake_port.uplink_status_propagation, ) return columns, data