Skip to content

Commit d3e9361

Browse files
author
Reedip
committed
Fix Quota Support for HMs
Health Monitors could not be updated using the `openstack quota update` CLI. This patch fixes the same. Change-Id: Ic5a4fa5dce5767e40139137131114834d564f89a Closes-Bug: #1624225
1 parent 276675f commit d3e9361

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

openstackclient/common/quota.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
'vip': 'vips',
7676
'subnetpool': 'subnetpools',
7777
'member': 'members',
78-
'health_monitor': 'health-monitors',
78+
'healthmonitor': 'health-monitors',
7979
}
8080

8181

openstackclient/tests/unit/common/test_quota.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ def test_quota_set_network(self):
250250
'--ports', str(network_fakes.QUOTA['port']),
251251
'--vips', str(network_fakes.QUOTA['vip']),
252252
'--members', str(network_fakes.QUOTA['member']),
253-
'--health-monitors', str(network_fakes.QUOTA['health_monitor']),
253+
'--health-monitors', str(network_fakes.QUOTA['healthmonitor']),
254254
identity_fakes.project_name,
255255
]
256256
verifylist = [
@@ -266,7 +266,7 @@ def test_quota_set_network(self):
266266
('port', network_fakes.QUOTA['port']),
267267
('vip', network_fakes.QUOTA['vip']),
268268
('member', network_fakes.QUOTA['member']),
269-
('health_monitor', network_fakes.QUOTA['health_monitor']),
269+
('healthmonitor', network_fakes.QUOTA['healthmonitor']),
270270
]
271271
parsed_args = self.check_parser(self.cmd, arglist, verifylist)
272272

@@ -284,7 +284,7 @@ def test_quota_set_network(self):
284284
'port': network_fakes.QUOTA['port'],
285285
'vip': network_fakes.QUOTA['vip'],
286286
'member': network_fakes.QUOTA['member'],
287-
'health_monitor': network_fakes.QUOTA['health_monitor'],
287+
'healthmonitor': network_fakes.QUOTA['healthmonitor'],
288288
}
289289
self.network_mock.update_quota.assert_called_once_with(
290290
identity_fakes.project_id,

openstackclient/tests/unit/network/v2/fakes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"port": 50,
3434
"vip": 10,
3535
"member": 10,
36-
"health_monitor": 10,
36+
"healthmonitor": 10,
3737
}
3838

3939

0 commit comments

Comments
 (0)