1
0
mirror of https://github.com/nix-community/home-manager synced 2024-06-05 22:43:34 +02:00
home-manager/tests/modules/programs/neomutt/neomutt.nix
Robert Helgesson ef4370bedc
tests: allow testing assertions
By default tests are expected to produce no assertion.

This also updates the existing tests to match.
2021-02-07 22:48:22 +01:00

42 lines
935 B
Nix

{ config, lib, pkgs, ... }:
with lib;
{
imports = [ ../../accounts/email-test-accounts.nix ];
config = {
accounts.email.accounts = {
"hm@example.com" = {
notmuch.enable = true;
neomutt = {
enable = true;
extraConfig = ''
color status cyan default
'';
};
imap.port = 993;
};
};
programs.neomutt = {
enable = true;
vimKeys = false;
};
nixpkgs.overlays =
[ (self: super: { neomutt = pkgs.writeScriptBin "dummy-neomutt" ""; }) ];
nmt.script = ''
assertFileExists home-files/.config/neomutt/neomuttrc
assertFileExists home-files/.config/neomutt/hm@example.com
assertFileContent home-files/.config/neomutt/neomuttrc ${
./neomutt-expected.conf
}
assertFileContent home-files/.config/neomutt/hm@example.com ${
./hm-example.com-expected
}
'';
};
}