1 import ./make-test-python.nix ({ pkgs, ...} : {
4 maintainers = with pkgs.lib.maintainers; [ rhysmdnz ];
10 let user = nodes.machine.users.users.alice;
12 services.intune.enable=true;
13 services.gnome.gnome-keyring.enable = true;
14 imports = [ ./common/user-account.nix ./common/x11.nix ];
15 test-support.displayManager.auto.user = user.name;
17 variables.DBUS_SESSION_BUS_ADDRESS = "unix:path=/run/user/${builtins.toString user.uid}/bus";
22 let user = nodes.machine.users.users.alice;
24 services.intune.enable=true;
25 imports = [ ./common/user-account.nix ];
31 # Check System Daemons successfully start
32 machine.succeed("systemctl start microsoft-identity-device-broker.service")
33 machine.succeed("systemctl start intune-daemon.service")
35 # Check User Daemons and intune-portal execurtable works
36 # Going any further than starting it would require internet access and a microsoft account
38 # TODO: This needs an unlocked user keychain before it will work
39 #machine.succeed("su - alice -c 'systemctl start --user microsoft-identity-broker.service'")
40 machine.succeed("su - alice -c 'systemctl start --user intune-agent.service'")
41 machine.succeed("su - alice -c intune-portal >&2 &")
42 machine.wait_for_text("Intune Agent")
44 # Check logging in creates password file
46 pam.wait_until_tty_matches("1", "login: ")
47 pam.send_chars("alice\n")
48 pam.wait_until_tty_matches("1", "Password: ")
49 pam.send_chars("foobar\n")
50 pam.wait_until_tty_matches("1", "alice\@pam")
52 pam.wait_for_unit("multi-user.target")
54 pam.wait_for_file("/run/intune/1000/pwquality")