From 00efa2d4c2f3c82fb920715f78388bfc9798867c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Na=C3=AFm=20Favier?= Date: Sat, 25 Feb 2023 00:46:15 +0100 Subject: [PATCH] [backport 22.11] tests: fix gnupg stub (#3702) systemd now depends on `gnupg.override`, so we need a stub for systemd too. (cherry picked from commit 7ff468105d84e071d2a61cb57d61b6ac48186f6e) --- tests/modules/programs/gpg/mutable-keyfiles.nix | 1 + tests/modules/services/gpg-agent/default-homedir.nix | 1 + tests/modules/services/gpg-agent/override-homedir.nix | 1 + 3 files changed, 3 insertions(+) diff --git a/tests/modules/programs/gpg/mutable-keyfiles.nix b/tests/modules/programs/gpg/mutable-keyfiles.nix index 588c9070..d2028e4b 100644 --- a/tests/modules/programs/gpg/mutable-keyfiles.nix +++ b/tests/modules/programs/gpg/mutable-keyfiles.nix @@ -14,6 +14,7 @@ }; test.stubs.gnupg = { }; + test.stubs.systemd = { }; # depends on gnupg.override nmt.script = '' assertFileContains activate "export GNUPGHOME='/home/hm-user/.gnupg'" diff --git a/tests/modules/services/gpg-agent/default-homedir.nix b/tests/modules/services/gpg-agent/default-homedir.nix index faf15374..9e21eb6d 100644 --- a/tests/modules/services/gpg-agent/default-homedir.nix +++ b/tests/modules/services/gpg-agent/default-homedir.nix @@ -9,6 +9,7 @@ with lib; programs.gpg.enable = true; test.stubs.gnupg = { }; + test.stubs.systemd = { }; # depends on gnupg.override nmt.script = '' in="${config.systemd.user.sockets.gpg-agent.Socket.ListenStream}" diff --git a/tests/modules/services/gpg-agent/override-homedir.nix b/tests/modules/services/gpg-agent/override-homedir.nix index 23d9f876..1a314e41 100644 --- a/tests/modules/services/gpg-agent/override-homedir.nix +++ b/tests/modules/services/gpg-agent/override-homedir.nix @@ -12,6 +12,7 @@ with lib; }; test.stubs.gnupg = { }; + test.stubs.systemd = { }; # depends on gnupg.override nmt.script = '' in="${config.systemd.user.sockets.gpg-agent.Socket.ListenStream}"