gnu: shfmt: Activate tests.

* gnu/packages/shellutils.scm (shfmt): Activate tests.
[native-inputs]: Remove go-github-com-frankban-quicktest and
go-github-com-pkg-diff; add go-github-com-go-quicktest-qt and
go-github-com-muesli-cancelreader.

Change-Id: Ib11765afb102d1bbb947e41988c9ac6403c694df
This commit is contained in:
Sharlatan Hellseher 2024-08-23 16:25:52 +01:00
parent 48f5df83df
commit 6d43590d46
No known key found for this signature in database
GPG key ID: 76D727BFF62CD2B5

View file

@ -436,13 +436,19 @@ (define-public shfmt
(("version = \"\\(devel\\)\"")
(format #f "version = \"~a\"" fixed-version)))
(substitute* "cmd/shfmt/testdata/script/flags.txtar"
(("devel\\|v3") #$version)))))))))
(("devel\\|v3") #$version))))))
;; XXX: Replace when go-build-system supports nested path.
(replace 'check
(lambda* (#:key import-path tests? #:allow-other-keys)
(when tests?
(with-directory-excursion (string-append "src/" import-path)
(invoke "go" "test" "-v" "./..."))))))))
(native-inputs
(list go-github-com-creack-pty
go-github-com-frankban-quicktest
go-github-com-go-quicktest-qt
go-github-com-google-go-cmp
go-github-com-google-renameio-v2
go-github-com-pkg-diff
go-github-com-muesli-cancelreader
go-github-com-rogpeppe-go-internal
go-golang-org-x-sync
go-golang-org-x-sys