nixosTests.domination: init

main
Francesco Gazzetta 3 years ago
parent df177cf39b
commit df99f2326e
  1. 1
      nixos/tests/all-tests.nix
  2. 26
      nixos/tests/domination.nix
  3. 5
      pkgs/games/domination/default.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 {};

@ -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")
'';
})

@ -6,6 +6,7 @@
, ant
, makeWrapper
, makeDesktopItem
, nixosTests
}:
let
@ -79,6 +80,10 @@ in stdenv.mkDerivation {
install -Dm644 build/game/resources/icon.png $out/share/pixmaps/domination.png
'';
passthru.tests = {
domination-starts = nixosTests.domination;
};
meta = with lib; {
homepage = "http://domination.sourceforge.net/";
downloadPage = "http://domination.sourceforge.net/download.shtml";

Loading…
Cancel
Save