From 0da421ce17a0226e4880c596702adcc58cb19d6c Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Tue, 28 Feb 2017 19:09:56 -0600 Subject: nixos/tests: fix Plasma 5 test --- nixos/release-combined.nix | 2 +- nixos/release.nix | 2 +- nixos/tests/kde5.nix | 50 --------------------------------------------- nixos/tests/plasma5.nix | 51 ++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 53 insertions(+), 52 deletions(-) delete mode 100644 nixos/tests/kde5.nix create mode 100644 nixos/tests/plasma5.nix diff --git a/nixos/release-combined.nix b/nixos/release-combined.nix index 6c048e8a0ac..341724b5847 100644 --- a/nixos/release-combined.nix +++ b/nixos/release-combined.nix @@ -72,7 +72,7 @@ in rec { (all nixos.tests.ecryptfs) (all nixos.tests.ipv6) (all nixos.tests.i3wm) - (all nixos.tests.kde5) + (all nixos.tests.plasma5) #(all nixos.tests.lightdm) (all nixos.tests.login) (all nixos.tests.misc) diff --git a/nixos/release.nix b/nixos/release.nix index 2bfe8eada0b..face44b94e2 100644 --- a/nixos/release.nix +++ b/nixos/release.nix @@ -255,7 +255,7 @@ in rec { tests.influxdb = callTest tests/influxdb.nix {}; tests.ipv6 = callTest tests/ipv6.nix {}; tests.jenkins = callTest tests/jenkins.nix {}; - tests.kde5 = callTest tests/kde5.nix {}; + tests.plasma5 = callTest tests/plasma5.nix {}; tests.keymap = callSubTests tests/keymap.nix {}; tests.initrdNetwork = callTest tests/initrd-network.nix {}; tests.keystone = callTest tests/keystone.nix {}; diff --git a/nixos/tests/kde5.nix b/nixos/tests/kde5.nix deleted file mode 100644 index 2b61d6f3f0a..00000000000 --- a/nixos/tests/kde5.nix +++ /dev/null @@ -1,50 +0,0 @@ -import ./make-test.nix ({ pkgs, ...} : - -{ - name = "kde5"; - meta = with pkgs.stdenv.lib.maintainers; { - maintainers = [ ttuegel ]; - }; - - machine = { lib, ... }: { - imports = [ ./common/user-account.nix ]; - virtualisation.memorySize = 1024; - services.xserver.enable = true; - services.xserver.displayManager.sddm = { - enable = true; - autoLogin = { - enable = true; - user = "alice"; - }; - }; - services.xserver.desktopManager.kde5.enable = true; - virtualisation.writableStore = false; # FIXME - }; - - testScript = { nodes, ... }: - let xdo = "${pkgs.xdotool}/bin/xdotool"; in - '' - startAll; - - $machine->waitForFile("/home/alice/.Xauthority"); - $machine->succeed("xauth merge ~alice/.Xauthority"); - - $machine->waitUntilSucceeds("pgrep plasmashell"); - $machine->waitForWindow("^Desktop "); - - # Check that logging in has given the user ownership of devices. - $machine->succeed("getfacl /dev/snd/timer | grep -q alice"); - - $machine->execute("su - alice -c 'DISPLAY=:0.0 dolphin &'"); - $machine->waitForWindow(" Dolphin"); - - $machine->execute("su - alice -c 'DISPLAY=:0.0 konsole &'"); - $machine->waitForWindow("Konsole"); - - $machine->execute("su - alice -c 'DISPLAY=:0.0 systemsettings5 &'"); - $machine->waitForWindow("Settings"); - - $machine->execute("${xdo} key Alt+F1 sleep 10"); - $machine->screenshot("screen"); - ''; -}) diff --git a/nixos/tests/plasma5.nix b/nixos/tests/plasma5.nix new file mode 100644 index 00000000000..3dd5121607a --- /dev/null +++ b/nixos/tests/plasma5.nix @@ -0,0 +1,51 @@ +import ./make-test.nix ({ pkgs, ...} : + +{ + name = "kde5"; + meta = with pkgs.stdenv.lib.maintainers; { + maintainers = [ ttuegel ]; + }; + + machine = { lib, ... }: { + imports = [ ./common/user-account.nix ]; + virtualisation.memorySize = 1024; + services.xserver.enable = true; + services.xserver.displayManager.sddm = { + enable = true; + autoLogin = { + enable = true; + user = "alice"; + }; + }; + services.xserver.desktopManager.plasma5.enable = true; + services.xserver.desktopManager.default = "plasma5"; + virtualisation.writableStore = false; # FIXME + }; + + testScript = { nodes, ... }: + let xdo = "${pkgs.xdotool}/bin/xdotool"; in + '' + startAll; + + $machine->waitForFile("/home/alice/.Xauthority"); + $machine->succeed("xauth merge ~alice/.Xauthority"); + + $machine->waitUntilSucceeds("pgrep plasmashell"); + $machine->waitForWindow("^Desktop "); + + # Check that logging in has given the user ownership of devices. + $machine->succeed("getfacl /dev/snd/timer | grep -q alice"); + + $machine->execute("su - alice -c 'DISPLAY=:0.0 dolphin &'"); + $machine->waitForWindow(" Dolphin"); + + $machine->execute("su - alice -c 'DISPLAY=:0.0 konsole &'"); + $machine->waitForWindow("Konsole"); + + $machine->execute("su - alice -c 'DISPLAY=:0.0 systemsettings5 &'"); + $machine->waitForWindow("Settings"); + + $machine->execute("${xdo} key Alt+F1 sleep 10"); + $machine->screenshot("screen"); + ''; +}) -- cgit 1.4.1