summaryrefslogtreecommitdiffstats
path: root/nixos/tests
diff options
context:
space:
mode:
authorFrancesco Gazzetta <fgaz@fgaz.me>2021-11-13 23:00:20 +0100
committerFrancesco Gazzetta <fgaz@fgaz.me>2021-11-13 23:00:20 +0100
commitdf99f2326ee60ea5e44ecea403f92d98313e1a1f (patch)
treee93543275cb9e60c6951dec7938ce266278e575e /nixos/tests
parentdf177cf39b6d9e1a10967079cb32970401d91a25 (diff)
nixosTests.domination: init
Diffstat (limited to 'nixos/tests')
-rw-r--r--nixos/tests/all-tests.nix1
-rw-r--r--nixos/tests/domination.nix26
2 files changed, 27 insertions, 0 deletions
diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix
index 0ee91ebffbed..deed04697de5 100644
--- a/nixos/tests/all-tests.nix
+++ b/nixos/tests/all-tests.nix
@@ -109,6 +109,7 @@ in
docker-tools-overlay = handleTestOn ["x86_64-linux"] ./docker-tools-overlay.nix {};
documize = handleTest ./documize.nix {};
dokuwiki = handleTest ./dokuwiki.nix {};
+ domination = handleTest ./domination.nix {};
dovecot = handleTest ./dovecot.nix {};
ec2-config = (handleTestOn ["x86_64-linux"] ./ec2.nix {}).boot-ec2-config or {};
ec2-nixops = (handleTestOn ["x86_64-linux"] ./ec2.nix {}).boot-ec2-nixops or {};
diff --git a/nixos/tests/domination.nix b/nixos/tests/domination.nix
new file mode 100644
index 000000000000..c76d4ed8c61b
--- /dev/null
+++ b/nixos/tests/domination.nix
@@ -0,0 +1,26 @@
+import ./make-test-python.nix ({ pkgs, ... }: {
+ name = "domination";
+ meta = with pkgs.lib.maintainers; {
+ maintainers = [ fgaz ];
+ };
+
+ machine = { config, pkgs, ... }: {
+ imports = [
+ ./common/x11.nix
+ ];
+
+ services.xserver.enable = true;
+ environment.systemPackages = [ pkgs.domination ];
+ };
+
+ enableOCR = true;
+
+ testScript =
+ ''
+ machine.wait_for_x()
+ machine.execute("domination >&2 &")
+ machine.wait_for_window("Menu")
+ machine.wait_for_text("New Game")
+ machine.screenshot("screen")
+ '';
+})