tests: register dynamically-created machines with the driver

The nixpkgs test driver was refactored: `driver.machines` is now a
computed property that returns a fresh sorted list combining
`driver.machines_qemu` and `driver.machines_nspawn`. Appending to the
property therefore mutates only the temporary returned list, so the
machines created via `create_test_machine` are no longer registered
with the driver.
This commit is contained in:
a-kenji authored and Michael Hoang committed 2026-05-19 16:50:50 +02:00
1 parent 17e2eee822
commit 8ebce63228
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -342,7 +342,7 @@ let
]
''}
machine = create_machine(start_command=" ".join(start_command), **kwargs)
driver.machines.append(machine)
driver.machines_qemu.append(machine)
return machine
machine.start()
+1 -1
View File
@@ -48,7 +48,7 @@ pkgs.testers.nixosTest {
"virtio-blk-pci,drive=drive1",
]
machine = create_machine(start_command=" ".join(start_command), **kwargs)
driver.machines.append(machine)
driver.machines_qemu.append(machine)
return machine
machine.succeed("lsblk >&2")