My personal project and infrastructure archive
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nomicon/nixos/tests/xautolock.nix

24 lines
530 B

import ./make-test-python.nix ({ pkgs, lib, ... }:
with lib;
{
name = "xautolock";
meta.maintainers = with pkgs.lib.maintainers; [ ];
nodes.machine = {
imports = [ ./common/x11.nix ./common/user-account.nix ];
test-support.displayManager.auto.user = "bob";
services.xserver.xautolock.enable = true;
services.xserver.xautolock.time = 1;
};
testScript = ''
machine.start()
machine.wait_for_x()
machine.fail("pgrep xlock")
machine.sleep(120)
machine.succeed("pgrep xlock")
'';
})