summary refs log tree commit diff
path: root/nixos/tests/non-switchable-system.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/tests/non-switchable-system.nix')
-rw-r--r--nixos/tests/non-switchable-system.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/nixos/tests/non-switchable-system.nix b/nixos/tests/non-switchable-system.nix
new file mode 100644
index 00000000000..54bede75453
--- /dev/null
+++ b/nixos/tests/non-switchable-system.nix
@@ -0,0 +1,15 @@
+{ lib, ... }:
+
+{
+  name = "non-switchable-system";
+
+  meta.maintainers = with lib.maintainers; [ nikstur ];
+
+  nodes.machine = {
+    system.switch.enable = false;
+  };
+
+  testScript = ''
+    machine.succeed("test ! -e /run/current-system/bin/switch-to-configuration")
+  '';
+}