1 import ./make-test-python.nix ({ pkgs, ... }:
5 meta = with pkgs.lib.maintainers; {
6 maintainers = [ bjornfor ];
11 { services.atd.enable = true;
12 users.users.alice = { isNormalUser = true; };
15 # "at" has a resolution of 1 minute
19 machine.wait_for_unit("atd.service") # wait for atd to start
20 machine.fail("test -f ~root/at-1")
21 machine.fail("test -f ~alice/at-1")
23 machine.succeed("echo 'touch ~root/at-1' | at now+1min")
24 machine.succeed("su - alice -c \"echo 'touch at-1' | at now+1min\"")
26 machine.succeed("sleep 1.5m")
28 machine.succeed("test -f ~root/at-1")
29 machine.succeed("test -f ~alice/at-1")