git.iko.soy/typeable/nixpkgs
on master help sign in
nixosTests.xfce4-14: init

This is pretty much identical to the xfce test we currently have.

commitfd7d31b50e087e790443cd57eaf52f41c3f99af1 authorworldofpeace <worldofpeace@protonmail.ch> dateWed 21 Aug 2019, 22:04 (7 years ago) parentde89ad1
3 files changed+35
nixos/release-combined.nix+1 nixos/tests/all-tests.nix+1 nixos/tests/xfce4-14.nix+33
nixos/release-combined.nix+1
@@ -136,6 +136,7 @@ in rec {
136136 (all nixos.tests.switchTest)
137137 (all nixos.tests.udisks2)
138138 (all nixos.tests.xfce)
139+ (all nixos.tests.xfce4-14)
139140
140141 nixpkgs.tarball
141142 (all allSupportedNixpkgs.emacs)
nixos/tests/all-tests.nix+1
@@ -273,6 +273,7 @@ in
273273 xautolock = handleTest ./xautolock.nix {};
274274 xdg-desktop-portal = handleTest ./xdg-desktop-portal.nix {};
275275 xfce = handleTest ./xfce.nix {};
276+ xfce4-14 = handleTest ./xfce4-14.nix {};
276277 xmonad = handleTest ./xmonad.nix {};
277278 xrdp = handleTest ./xrdp.nix {};
278279 xss-lock = handleTest ./xss-lock.nix {};
nixos/tests/xfce4-14.nixnew file+33
@@ -0,0 +1,33 @@
1+import ./make-test.nix ({ pkgs, ...} : {
2+ name = "xfce4-14";
3+
4+ machine =
5+ { pkgs, ... }:
6+
7+ { imports = [ ./common/user-account.nix ];
8+
9+ services.xserver.enable = true;
10+
11+ services.xserver.displayManager.auto.enable = true;
12+ services.xserver.displayManager.auto.user = "alice";
13+
14+ services.xserver.desktopManager.xfce4-14.enable = true;
15+ };
16+
17+ testScript =
18+ ''
19+ $machine->waitForX;
20+ $machine->waitForFile("/home/alice/.Xauthority");
21+ $machine->succeed("xauth merge ~alice/.Xauthority");
22+ $machine->waitForWindow(qr/xfce4-panel/);
23+ $machine->sleep(10);
24+
25+ # Check that logging in has given the user ownership of devices.
26+ $machine->succeed("getfacl /dev/snd/timer | grep -q alice");
27+
28+ $machine->succeed("su - alice -c 'DISPLAY=:0.0 xfce4-terminal &'");
29+ $machine->waitForWindow(qr/Terminal/);
30+ $machine->sleep(10);
31+ $machine->screenshot("screen");
32+ '';
33+})