1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2024-12-14 11:57:55 +00:00

manual: add test

This checks that the documentation can be built in the context of a
Home Manager configuration.
This commit is contained in:
Emily 2023-06-29 04:07:31 +01:00
parent 2f84579a70
commit 1add3c3a99
3 changed files with 22 additions and 1 deletions

View file

@ -30,7 +30,7 @@ let
# Avoid including documentation since this will cause
# unnecessary rebuilds of the tests.
manual.manpages.enable = false;
manual.manpages.enable = lib.mkDefault false;
imports = [ ./asserts.nix ./big-test.nix ./stubs.nix ];
@ -52,6 +52,7 @@ import nmt {
./modules/files
./modules/home-environment
./modules/misc/fontconfig
./modules/misc/manual
./modules/misc/nix
./modules/misc/specialisation
./modules/programs/aerc

View file

@ -0,0 +1 @@
{ manual = ./manual.nix; }

View file

@ -0,0 +1,19 @@
{ ... }:
{
config = {
manual = {
html.enable = true;
manpages.enable = true;
json.enable = true;
};
nmt.script = ''
assertFileExists home-path/share/doc/home-manager/index.html
assertFileExists home-path/share/doc/home-manager/options.html
assertFileExists home-path/share/doc/home-manager/options.json
assertFileExists home-path/share/man/man1/home-manager.1.gz
assertFileExists home-path/share/man/man5/home-configuration.nix.5.gz
'';
};
}