sil-q: add a test

Check whether creating the save directory works (as a test in
passthru.tests).
This commit is contained in:
Johannes Maier 2022-06-15 23:22:33 +02:00
parent 3876d53242
commit 44feda004b

View file

@ -1,4 +1,4 @@
{ lib, stdenv, fetchFromGitHub, writeScript, makeWrapper, ncurses, libX11 }:
{ pkgs, lib, stdenv, fetchFromGitHub, writeScript, makeWrapper, ncurses, libX11 }:
let
setup = writeScript "setup" ''
@ -47,6 +47,13 @@ in stdenv.mkDerivation rec {
runHook postInstall
'';
passthru.tests = {
saveDirCreation = pkgs.runCommand "save-dir-creation" {} ''
HOME=$(pwd) ${lib.getExe pkgs.sil-q} --help
test -d .sil && touch $out
'';
};
meta = {
description = "A roguelike game set in the First Age of Middle-earth";
longDescription = ''