mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-09-11 07:15:54 +03:00
nixosTests.watchdogd: init
This commit is contained in:
parent
58cbe00eb6
commit
07d610c8ab
@ -944,6 +944,7 @@ in {
|
||||
vsftpd = handleTest ./vsftpd.nix {};
|
||||
warzone2100 = handleTest ./warzone2100.nix {};
|
||||
wasabibackend = handleTest ./wasabibackend.nix {};
|
||||
watchdogd = handleTest ./watchdogd.nix {};
|
||||
webhook = runTest ./webhook.nix;
|
||||
wiki-js = handleTest ./wiki-js.nix {};
|
||||
wine = handleTest ./wine.nix {};
|
||||
|
22
nixos/tests/watchdogd.nix
Normal file
22
nixos/tests/watchdogd.nix
Normal file
@ -0,0 +1,22 @@
|
||||
import ./make-test-python.nix ({ lib, ... }: {
|
||||
name = "watchdogd";
|
||||
meta.maintainers = with lib.maintainers; [ vifino ];
|
||||
|
||||
nodes.machine = { pkgs, ... }: {
|
||||
virtualisation.qemu.options = [
|
||||
"-device i6300esb" # virtual watchdog timer
|
||||
];
|
||||
boot.kernelModules = [ "i6300esb" ];
|
||||
services.watchdogd.enable = true;
|
||||
services.watchdogd.settings = {
|
||||
supervisor.enabled = true;
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
machine.wait_for_unit("watchdogd.service")
|
||||
|
||||
assert "i6300ESB" in machine.succeed("watchdogctl status")
|
||||
machine.succeed("watchdogctl test")
|
||||
'';
|
||||
})
|
Loading…
Reference in New Issue
Block a user