1 import ./make-test-python.nix ({ lib, ... }: {
2 name = "user-home-mode";
3 meta = with lib.maintainers; { maintainers = [ fbeffa ]; };
7 initialPassword = "pass1";
11 initialPassword = "pass2";
16 initialPassword = "pass3";
19 home = "/users/carol";
24 machine.wait_for_unit("multi-user.target")
25 machine.wait_for_unit("getty@tty1.service")
26 machine.wait_until_tty_matches("1", "login: ")
27 machine.send_chars("alice\n")
28 machine.wait_until_tty_matches("1", "Password: ")
29 machine.send_chars("pass1\n")
30 machine.succeed('[ "$(stat -c %a /home/alice)" == "700" ]')
31 machine.succeed('[ "$(stat -c %a /home/bob)" == "750" ]')
32 machine.succeed('[ "$(stat -c %a /users)" == "755" ]')
33 machine.succeed('[ "$(stat -c %a /users/carol)" == "700" ]')