[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
17/27: gnu: go-github-com-rogpeppe-go-internal: Enable tests.
From: |
guix-commits |
Subject: |
17/27: gnu: go-github-com-rogpeppe-go-internal: Enable tests. |
Date: |
Sun, 11 Aug 2024 17:11:24 -0400 (EDT) |
sharlatan pushed a commit to branch go-team
in repository guix.
commit b313bdc7e739244d88994976fcc2954d4ba10d49
Author: Sharlatan Hellseher <sharlatanus@gmail.com>
AuthorDate: Fri Aug 9 21:45:43 2024 +0100
gnu: go-github-com-rogpeppe-go-internal: Enable tests.
* gnu/packages/golang-xyz.scm (go-github-com-rogpeppe-go-internal):
Enable tests.
[arguments]: <#:phases>: Add 'disable-failing-tests phase; use custom
'check phase.
[propagated-inputs]: Remove go-github-com-pkg-diff; add go-golang-org-x-mod,
go-golang-org-x-sys, and go-golang-org-x-tools.
Change-Id: Ia937113bd690cee9d954c0b5b53b6067f8e447ba
---
gnu/packages/golang-xyz.scm | 26 +++++++++++++++++++-------
1 file changed, 19 insertions(+), 7 deletions(-)
diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index 26fdf7671f..2aa86d5bb1 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -4752,18 +4752,30 @@ not overload the given database.")
(arguments
(list
#:import-path "github.com/rogpeppe/go-internal"
- ;; Source-only package
- #:tests? #f
#:phases
#~(modify-phases %standard-phases
- (delete 'build))))
+ (add-after 'unpack 'disable-failing-tests
+ (lambda* (#:key tests? import-path #:allow-other-keys)
+ (with-directory-excursion (string-append "src/" import-path)
+ (substitute* (find-files "." "\\_test.go$")
+ (("TestSimple") "OffTestSimple")))))
+ ;; XXX: Replace when go-build-system supports nested path.
+ (delete 'build)
+ (replace 'check
+ (lambda* (#:key import-path tests? #:allow-other-keys)
+ (when tests?
+ (with-directory-excursion (string-append "src/" import-path)
+ (invoke "go" "test" "-v" "./..."))))))))
(propagated-inputs
- (list go-github-com-pkg-diff))
+ (list go-golang-org-x-mod
+ go-golang-org-x-sys
+ go-golang-org-x-tools))
(home-page "https://github.com/rogpeppe/go-internal/")
(synopsis "Internal packages from the Go standard library")
- (description "This repository factors out an opinionated selection of
-internal packages and functionality from the Go standard library. Currently
-this consists mostly of packages and testing code from within the Go tool
+ (description
+ "This repository factors out an opinionated selection of internal
+packages and functionality from the Go standard library. Currently this
+consists mostly of packages and testing code from within the Go tool
implementation.
Included are the following:
- 14/27: gnu: go-github-com-delthas-go-localeinfo: Fix indentation., (continued)
- 14/27: gnu: go-github-com-delthas-go-localeinfo: Fix indentation., guix-commits, 2024/08/11
- 19/27: gnu: go-mvdan-cc-xurls: Update to 2.5.0., guix-commits, 2024/08/11
- 20/27: gnu: go-mvdan-cc-xurls: Move to golang-web., guix-commits, 2024/08/11
- 16/27: gnu: go-github-com-rogpeppe-go-internal: Move to golang-xyz., guix-commits, 2024/08/11
- 18/27: gnu: go-mvdan-cc-xurls: Swap inheritance., guix-commits, 2024/08/11
- 22/27: gnu: go-github-com-gdamore-tcell-v2: Update to 2.7.4., guix-commits, 2024/08/11
- 23/27: gnu: go-git-sr-ht-emersion-go-scfg: Adjust inputs., guix-commits, 2024/08/11
- 13/27: gnu: go-github-com-delthas-go-localeinfo: Update to 0.0.0-20240607105203-b2e834fc307d., guix-commits, 2024/08/11
- 21/27: gnu: senpai: Update source and hompe-page URLs., guix-commits, 2024/08/11
- 02/27: gnu: go-golang-org-x-exp: Update to 0.0.0-20240808152545-0cdaa3abc0fa., guix-commits, 2024/08/11
- 17/27: gnu: go-github-com-rogpeppe-go-internal: Enable tests.,
guix-commits <=
- 24/27: gnu: kiln: Update to 0.4.1., guix-commits, 2024/08/11
- 25/27: gnu: go-github-com-google-shlex: Add project status comment., guix-commits, 2024/08/11
- 26/27: gnu: Add go-github-com-charlievieth-fastwalk., guix-commits, 2024/08/11
- 27/27: gnu: go-github-com-junegunn-fzf: Update to 0.54.3., guix-commits, 2024/08/11