nixos-functions: Set system.stateVersion

This commit is contained in:
Janne Heß 2022-05-05 12:51:39 +02:00
parent 4c5e7bde3e
commit 0329256fd8
No known key found for this signature in database
GPG key ID: 69165158F05265DF

View file

@ -24,6 +24,7 @@ in lib.optionalAttrs stdenv.hostPlatform.isLinux (
system.nixos = dummyVersioning;
boot.loader.grub.enable = false;
fileSystems."/".device = "/dev/null";
system.stateVersion = lib.trivial.release;
}).toplevel;
nixosTest-test = pkgs.nixosTest ({ lib, pkgs, figlet, ... }: {
@ -31,6 +32,7 @@ in lib.optionalAttrs stdenv.hostPlatform.isLinux (
nodes.machine = { pkgs, ... }: {
system.nixos = dummyVersioning;
environment.systemPackages = [ pkgs.hello figlet ];
system.stateVersion = lib.trivial.release;
};
testScript = ''
machine.succeed("hello | figlet >/dev/console")