summaryrefslogtreecommitdiff
path: root/gnu/packages
diff options
context:
space:
mode:
authorbdunahu <bdunahu@operationnull.com>2026-03-26 17:38:54 -0400
committerLiliana Marie Prikler <liliana.prikler@gmail.com>2026-04-04 18:27:03 +0200
commitcb714dcd256e765646460ee1aa7efc34536c6894 (patch)
treead902569243f35f0dec5f735e4d150e1fd2d6c48 /gnu/packages
parentddf9f96d916da7602e997fd7d9f5d217bcf59d8e (diff)
gnu: angband: Enable test suite.
* gnu/packages/games.scm (angband)[arguments]: <#:tests?>: Enable tests. <#:phases>: Add phase 'skip-failing-tests. [native-inputs]: Add perl. Change-Id: I8af02d830e394190954d5d3374f5eaec2cfc6cf6 Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/games.scm38
1 files changed, 34 insertions, 4 deletions
diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 04a934882bd..53521ab387f 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -3994,8 +3994,7 @@ that beneath its ruins lay buried an ancient evil.")
(delete-file-recursively "src/win")))))
(build-system gnu-build-system)
(arguments
- `(#:tests? #f ; no check target
- #:configure-flags (list (string-append "--bindir=" %output "/bin"))
+ `(#:configure-flags (list (string-append "--bindir=" %output "/bin"))
#:phases
(modify-phases %standard-phases
(add-before 'build 'fix-infinite-loop-on-sighup
@@ -4006,8 +4005,39 @@ that beneath its ruins lay buried an ancient evil.")
(lambda _
(substitute* "src/ui-signals.c"
(("(SIGHUP, )SIG_IGN" _ first)
- (string-append first "handle_signal_abort"))))))))
- (native-inputs (list autoconf automake))
+ (string-append first "handle_signal_abort")))))
+ (add-before 'check 'skip-failing-tests
+ (lambda _
+ (let ((to-skip '(;; some of these may be fixable, but most try to
+ ;; create a directory in the user's home directory.
+ ;; Rather than reading environment variables, they
+ ;; lookup the username using getpwnam(3) and manually
+ ;; construct the string.
+ ;; Generic "Suite died":
+ "game/basic"
+ "game/mage"
+ ;; "Cannot create '//.angband/Angband'":
+ "effects/chain"
+ "effects/destruction"
+ "effects/earthquake"
+ "object/info"
+ "object/slays"
+ "player/calc-inventory"
+ "player/combine-pack"
+ "player/digging"
+ "player/inven-carry-num"
+ "player/inven-wield"
+ "player/timed"
+ ;; This file likes to read /etc/passwd
+ "z-file/path-normalize")))
+ (substitute* "src/tests/Makefile"
+ (("include \\$\\(SUITES\\)" all)
+ (string-append all "\nTESTPROGS := $(filter-out "
+ (string-join to-skip " ")
+ ", $(TESTPROGS))")))))))))
+ (native-inputs (list autoconf
+ automake
+ perl)) ;for tests
(inputs (list ncurses))
(home-page "https://rephial.org/")
(synopsis "Dungeon exploration roguelike")