diff --git a/openstackclient/network/v2/subnet_pool.py b/openstackclient/network/v2/subnet_pool.py index 6b6fc090f9..f1fd9a61e9 100644 --- a/openstackclient/network/v2/subnet_pool.py +++ b/openstackclient/network/v2/subnet_pool.py @@ -184,7 +184,7 @@ class ListSubnetPool(command.Lister): return (headers, (utils.get_item_properties( s, columns, - formatters={}, + formatters=_formatters, ) for s in data)) diff --git a/openstackclient/tests/network/v2/test_subnet_pool.py b/openstackclient/tests/network/v2/test_subnet_pool.py index 093e26c67e..df4d27eba1 100644 --- a/openstackclient/tests/network/v2/test_subnet_pool.py +++ b/openstackclient/tests/network/v2/test_subnet_pool.py @@ -246,7 +246,7 @@ class TestListSubnetPool(TestSubnetPool): data.append(( pool.id, pool.name, - pool.prefixes, + utils.format_list(pool.prefixes), )) data_long = [] @@ -254,7 +254,7 @@ class TestListSubnetPool(TestSubnetPool): data_long.append(( pool.id, pool.name, - pool.prefixes, + utils.format_list(pool.prefixes), pool.default_prefixlen, pool.address_scope_id, )) diff --git a/releasenotes/notes/bug-1569480-c52e330548bfbd78.yaml b/releasenotes/notes/bug-1569480-c52e330548bfbd78.yaml new file mode 100644 index 0000000000..ccec658bc3 --- /dev/null +++ b/releasenotes/notes/bug-1569480-c52e330548bfbd78.yaml @@ -0,0 +1,7 @@ +--- +fixes: + - Fixed ``subnet pool list`` command to properly disply the + list of subnet pool prefixes in the ``Prefixes`` column. + This fix is consistent with the ``subnet pool create`` and + ``subnet pool show`` command output. + [Bug `1569480 `_]