about summary refs log tree commit diff
path: root/nixos/tests
diff options
context:
space:
mode:
authorJulien Malka <julien@malka.sh>2023-11-16 23:48:19 +0000
committerJulien Malka <julien@malka.sh>2023-11-17 14:39:04 +0100
commit81e378618e3f201e1d55abcbd920fdca394c21a5 (patch)
tree20a881bb044d717bd089801f67f30a9d26200451 /nixos/tests
parent4fae7293f40740bbc584df9056d8856a1c7b0dbe (diff)
nixos/systemd-boot: allow for bootspec-less generations
Generation built with old versions of NixOS with no bootspec
support may still be present on the system and must be
accounted for.
Diffstat (limited to 'nixos/tests')
-rw-r--r--nixos/tests/systemd-boot.nix16
1 files changed, 16 insertions, 0 deletions
diff --git a/nixos/tests/systemd-boot.nix b/nixos/tests/systemd-boot.nix
index 13007d0d80d84..a592504addc03 100644
--- a/nixos/tests/systemd-boot.nix
+++ b/nixos/tests/systemd-boot.nix
@@ -277,4 +277,20 @@ in
       machine.wait_for_unit("multi-user.target")
     '';
   };
+
+  no-bootspec = makeTest
+    {
+      name = "systemd-boot-no-bootspec";
+      meta.maintainers = with pkgs.lib.maintainers; [ julienmalka ];
+
+      nodes.machine = {
+        imports = [ common ];
+        boot.bootspec.enable = false;
+      };
+
+      testScript = ''
+        machine.start()
+        machine.wait_for_unit("multi-user.target")
+      '';
+    };
 }