From 179ffc105e883bd25198d7ba93279837c093cb59 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 15 Jan 2022 02:02:26 +0000 Subject: gnu: beep: Run tests. * gnu/packages/terminals.scm (beep)[arguments]: Remove #:tests? #f lie. Add a new 'patch-tests phase to make them pass. --- gnu/packages/terminals.scm | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 78eb34925f..e9e84d2e1f 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -573,13 +573,21 @@ to all types of devices that provide serial consoles.") (base32 "05c2gxfqc12rgp88c65q7f5ha9gzh222vdh0qpdq1zmyhqj43pq1")))) (build-system gnu-build-system) (arguments - `(#:tests? #f ; no tests - #:make-flags + `(#:make-flags (list (string-append "prefix=" (assoc-ref %outputs "out")) (string-append "pkgdocdir=$(docdir)/" ,name "-" ,version)) #:phases (modify-phases %standard-phases - (delete 'configure)))) ; no configure script + (delete 'configure) ; no configure script + (add-before 'check 'patch-tests + (lambda _ + (substitute* "GNUmakefile" + (("/bin/bash") + (which "bash"))) + (substitute* (find-files "tests" "\\.expected") + ;; The build environment lacks /dev/{console,tty*}. + ((": Permission denied") + ": No such file or directory"))))))) (synopsis "Linux command-line utility to control the PC speaker") (description "beep allows the user to control the PC speaker with precision, allowing different sounds to indicate different events. While it can be run -- cgit v1.2.3