From 0d55eebcf53fbdf2485429fb32956a60f6421e8d Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Sat, 10 Jun 2023 17:50:57 +0200 Subject: [PATCH 1/2] nixosTests.systemd-boot.switch-test: Fix test ... by making the alternate configs available in machine's store. --- nixos/tests/systemd-boot.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/nixos/tests/systemd-boot.nix b/nixos/tests/systemd-boot.nix index 19034b299999b..7143da7bf9954 100644 --- a/nixos/tests/systemd-boot.nix +++ b/nixos/tests/systemd-boot.nix @@ -207,11 +207,17 @@ in nodes = { inherit common; - machine = { pkgs, ... }: { + machine = { pkgs, nodes, ... }: { imports = [ common ]; boot.loader.systemd-boot.extraFiles = { "efi/fruits/tomato.efi" = pkgs.netbootxyz-efi; }; + + # These are configs for different nodes, but we'll use them here in `machine` + system.extraDependencies = [ + nodes.common.system.build.toplevel + nodes.with_netbootxyz.system.build.toplevel + ]; }; with_netbootxyz = { pkgs, ... }: { From a54e7d299b1dc3af4d6393527c9194ec4dfc6d68 Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Sat, 10 Jun 2023 17:51:44 +0200 Subject: [PATCH 2/2] nixosTests.systemd-boot.switch-test: Fix warnings --- nixos/tests/systemd-boot.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nixos/tests/systemd-boot.nix b/nixos/tests/systemd-boot.nix index 7143da7bf9954..814cdc5f14435 100644 --- a/nixos/tests/systemd-boot.nix +++ b/nixos/tests/systemd-boot.nix @@ -227,9 +227,9 @@ in }; testScript = { nodes, ... }: let - originalSystem = nodes.machine.config.system.build.toplevel; - baseSystem = nodes.common.config.system.build.toplevel; - finalSystem = nodes.with_netbootxyz.config.system.build.toplevel; + originalSystem = nodes.machine.system.build.toplevel; + baseSystem = nodes.common.system.build.toplevel; + finalSystem = nodes.with_netbootxyz.system.build.toplevel; in '' machine.succeed("test -e /boot/efi/fruits/tomato.efi") machine.succeed("test -e /boot/efi/nixos/.extra-files/efi/fruits/tomato.efi")