2015-07-12 13:09:40 +03:00
|
|
|
import ./make-test.nix ({ pkgs, ...} : {
|
2014-06-28 18:04:49 +04:00
|
|
|
name = "gnome3";
|
2015-07-12 13:09:40 +03:00
|
|
|
meta = with pkgs.stdenv.lib.maintainers; {
|
2016-05-17 14:57:28 +03:00
|
|
|
maintainers = [ domenkozar eelco chaoflow lethalman ];
|
2015-07-12 13:09:40 +03:00
|
|
|
};
|
2014-02-09 00:47:28 +04:00
|
|
|
|
|
|
|
machine =
|
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
{ imports = [ ./common/user-account.nix ];
|
|
|
|
|
|
|
|
services.xserver.enable = true;
|
|
|
|
|
2015-08-31 11:35:11 +03:00
|
|
|
services.xserver.displayManager.auto.enable = true;
|
|
|
|
services.xserver.displayManager.auto.user = "alice";
|
2014-02-09 00:47:28 +04:00
|
|
|
services.xserver.desktopManager.gnome3.enable = true;
|
2014-11-02 18:33:10 +03:00
|
|
|
|
|
|
|
virtualisation.memorySize = 512;
|
2014-02-09 00:47:28 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
testScript =
|
|
|
|
''
|
|
|
|
$machine->waitForX;
|
2015-08-31 11:35:11 +03:00
|
|
|
$machine->sleep(15);
|
2014-02-09 00:47:28 +04:00
|
|
|
|
|
|
|
# Check that logging in has given the user ownership of devices.
|
|
|
|
$machine->succeed("getfacl /dev/snd/timer | grep -q alice");
|
|
|
|
|
|
|
|
$machine->succeed("su - alice -c 'DISPLAY=:0.0 gnome-terminal &'");
|
2016-04-12 20:12:47 +03:00
|
|
|
$machine->succeed("xauth merge ~alice/.Xauthority");
|
2014-02-09 00:47:28 +04:00
|
|
|
$machine->waitForWindow(qr/Terminal/);
|
2015-10-06 07:10:40 +03:00
|
|
|
$machine->mustSucceed("timeout 900 bash -c 'journalctl -f|grep -m 1 \"GNOME Shell started\"'");
|
2015-09-30 19:29:08 +03:00
|
|
|
$machine->sleep(10);
|
2014-02-09 00:47:28 +04:00
|
|
|
$machine->screenshot("screen");
|
|
|
|
'';
|
2015-07-12 13:09:40 +03:00
|
|
|
})
|