about summary refs log tree commit diff
path: root/nixos/tests/gnome.nix
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2021-10-08 04:21:01 +0200
committerJan Tojnar <jtojnar@gmail.com>2021-10-09 21:35:57 +0200
commitb2ef3e68e7f4d805fcd2e71e992981c6dcc5e601 (patch)
treec14745ccbb6e79c9b4fb177beb445c61ecc41a33 /nixos/tests/gnome.nix
parentb9e4f6e1ab3893a6dd715369b273addab28a76b3 (diff)
nixosTests.gnome: fix
GNOME Shell 41 made the Eval command we use for NixOS tests internal
so in order to be still able to use it, we need to run the shell
in an unsafe mode.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1983

Hopefully, the test driver will eventually get better so that
we will not need hacks like this forever.
Diffstat (limited to 'nixos/tests/gnome.nix')
-rw-r--r--nixos/tests/gnome.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/nixos/tests/gnome.nix b/nixos/tests/gnome.nix
index e8d18a41bd064..1da97f733cfd8 100644
--- a/nixos/tests/gnome.nix
+++ b/nixos/tests/gnome.nix
@@ -30,6 +30,21 @@ import ./make-test-python.nix ({ pkgs, lib, ...} : {
         })
       ];
 
+      systemd.user.services = {
+        "org.gnome.Shell@wayland" = {
+          serviceConfig = {
+            ExecStart = [
+              # Clear the list before overriding it.
+              ""
+              # Eval API is now internal so Shell needs to run in unsafe mode.
+              # TODO: improve test driver so that it supports openqa-like manipulation
+              # that would allow us to drop this mess.
+              "${pkgs.gnome.gnome-shell}/bin/gnome-shell --unsafe-mode"
+            ];
+          };
+        };
+      };
+
       virtualisation.memorySize = 1024;
     };