mirror of
https://github.com/nix-community/home-manager
synced 2024-11-23 03:29:45 +01:00
volnoti: add test case
This commit is contained in:
parent
b7c7ff03b0
commit
7a8758875a
3 changed files with 29 additions and 0 deletions
|
@ -286,6 +286,7 @@ in import nmtSrc {
|
|||
./modules/services/trayscale
|
||||
./modules/services/twmn
|
||||
./modules/services/udiskie
|
||||
./modules/services/volnoti
|
||||
./modules/services/window-managers/bspwm
|
||||
./modules/services/window-managers/herbstluftwm
|
||||
./modules/services/window-managers/hyprland
|
||||
|
|
1
tests/modules/services/volnoti/default.nix
Normal file
1
tests/modules/services/volnoti/default.nix
Normal file
|
@ -0,0 +1 @@
|
|||
{ volnoti-package-option = ./package-option.nix; }
|
27
tests/modules/services/volnoti/package-option.nix
Normal file
27
tests/modules/services/volnoti/package-option.nix
Normal file
|
@ -0,0 +1,27 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
{
|
||||
services.volnoti = {
|
||||
enable = true;
|
||||
package = pkgs.writeShellScriptBin "fake-volnoti" ''
|
||||
true
|
||||
'';
|
||||
};
|
||||
|
||||
home.stateVersion = "24.05";
|
||||
|
||||
test.stubs.volnoti = { };
|
||||
|
||||
nmt.script = ''
|
||||
serviceFile=home-files/.config/systemd/user/volnoti.service
|
||||
assertFileExists $serviceFile
|
||||
|
||||
assertFileContains $serviceFile \
|
||||
'ExecStart=${lib.getExe config.services.volnoti.package}'
|
||||
|
||||
assertFileContains $serviceFile \
|
||||
'WantedBy=graphical-session.target'
|
||||
'';
|
||||
}
|
Loading…
Reference in a new issue