1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-19 09:39:45 +01:00
home-manager/tests/modules/programs/htop/settings-without-fields.nix
2021-08-16 23:31:59 +02:00

28 lines
660 B
Nix

{ config, lib, pkgs, ... }:
with lib;
{
config = {
programs.htop.enable = true;
programs.htop.settings = { color_scheme = 6; };
nixpkgs.overlays =
[ (self: super: { htop = pkgs.writeScriptBin "dummy" ""; }) ];
# Test that the 'fields' key is written in addition to the customized
# settings or htop won't read the options.
nmt.script = ''
htoprc=home-files/.config/htop/htoprc
assertFileExists $htoprc
assertFileContent $htoprc \
${
builtins.toFile "htoprc-expected" ''
color_scheme=6
fields=0 48 17 18 38 39 40 2 46 47 49 1
''
}
'';
};
}