ne: use dummy package in tests
This is to avoid unnecessary downloads and builds when running the tests suite.
This commit is contained in:
parent
54b69d2ef8
commit
5a15f3833d
|
@ -1,13 +1,16 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
let
|
let
|
||||||
defpref = ''
|
defpref = ''
|
||||||
defined through defaultPreferences
|
defined through defaultPreferences
|
||||||
'';
|
'';
|
||||||
|
|
||||||
autopref = ''
|
autopref = ''
|
||||||
defined through automaticPreferences
|
defined through automaticPreferences
|
||||||
'';
|
'';
|
||||||
|
|
||||||
in {
|
in {
|
||||||
config = {
|
config = {
|
||||||
programs.ne = {
|
programs.ne = {
|
||||||
|
@ -15,6 +18,10 @@ in {
|
||||||
defaultPreferences = defpref;
|
defaultPreferences = defpref;
|
||||||
automaticPreferences.".default" = autopref;
|
automaticPreferences.".default" = autopref;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nixpkgs.overlays =
|
||||||
|
[ (self: super: { ne = pkgs.writeScriptBin "dummy-ne" ""; }) ];
|
||||||
|
|
||||||
nmt = {
|
nmt = {
|
||||||
description =
|
description =
|
||||||
"Check that it gracefully handles the case of both defaultPreferences and automaticPreferences.'.default' being set, defaulting to the former.";
|
"Check that it gracefully handles the case of both defaultPreferences and automaticPreferences.'.default' being set, defaulting to the former.";
|
||||||
|
@ -24,7 +31,6 @@ in {
|
||||||
builtins.toFile "defpref" defpref
|
builtins.toFile "defpref" defpref
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,6 +53,9 @@ in {
|
||||||
inherit automaticPreferences;
|
inherit automaticPreferences;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nixpkgs.overlays =
|
||||||
|
[ (self: super: { ne = pkgs.writeScriptBin "dummy-ne" ""; }) ];
|
||||||
|
|
||||||
nmt = {
|
nmt = {
|
||||||
description = "Check that configuration files are correctly written";
|
description = "Check that configuration files are correctly written";
|
||||||
script = concatStringsSep "\n" [
|
script = concatStringsSep "\n" [
|
||||||
|
|
Loading…
Reference in a new issue