mirror of
https://github.com/retspen/webvirtcloud
synced 2026-12-01 16:36:06 +00:00
fix(instances): memory, boot order and QoS edits check what they change first
Three edits went wrong on input or a state made outside the panel:
- A running VM's memory was set live, then for its next start. When the
next start had a lower maximum (virsh --config), the live change was
made and the second one failed. The maximum of the next start is now
checked first.
- A boot order entry without its device type ("disk") raised an error
page. It is now refused with a message.
- A QoS form of a NIC whose MAC changed since redefined the VM unchanged
and said the QoS was set or deleted. It now says the NIC is not in the
definition.
Turkish and Chinese texts included.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Kk4h2TcUiaWmU5MUszYSea
This commit is contained in:
parent
63fb7defee
commit
015972dc38
8 changed files with 307 additions and 243 deletions
|
|
@ -45,6 +45,11 @@ class MissingFieldTestCase(TestCase):
|
|||
self.client.post(reverse("instances:add_network", args=[self.instance.id]), {})
|
||||
wvm.return_value.add_network.assert_not_called()
|
||||
|
||||
def test_set_bootorder_with_a_device_without_its_type(self):
|
||||
for order in ("disk", "disk:vda,", "disk:vda,:"):
|
||||
with self.subTest(order):
|
||||
self.assert_reported(self.post("set_bootorder", {"bootorder": order}))
|
||||
|
||||
def test_set_qos_without_a_mac(self):
|
||||
self.assert_reported(self.post("set_qos", {"qos_direction": "inbound"}))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue