nixos/tests: don't include switch-to-configuration in DUT by default
This commit is contained in:
parent
7771e0b943
commit
4cfbbb3c1d
@ -3,7 +3,7 @@
|
||||
# even in `inheritParentConfig = false` specialisations.
|
||||
{ lib, ... }:
|
||||
let
|
||||
inherit (lib) mkForce;
|
||||
inherit (lib) mkDefault mkForce;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
@ -22,6 +22,11 @@ in
|
||||
label = mkForce "test";
|
||||
};
|
||||
}
|
||||
|
||||
({ config, ... }: {
|
||||
# Don't pull in switch-to-configuration by default, except when specialisations are involved.
|
||||
# This is mostly a Hydra optimization, so we don't rebuild all the tests every time switch-to-configuration-ng changes.
|
||||
key = "no-switch-to-configuration";
|
||||
system.switch.enable = mkDefault (config.isSpecialisation || config.specialisation != {});
|
||||
})
|
||||
];
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user