guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

72/74: gnu: go-github-com-arceliar-ironwood: Enable tests.


From: guix-commits
Subject: 72/74: gnu: go-github-com-arceliar-ironwood: Enable tests.
Date: Thu, 25 Jul 2024 18:02:30 -0400 (EDT)

sharlatan pushed a commit to branch go-team
in repository guix.

commit 7a6f5b05028af5a2796bcf3205d5ac63ddeb2c0e
Author: Sharlatan Hellseher <sharlatanus@gmail.com>
AuthorDate: Thu Jul 25 22:36:06 2024 +0100

    gnu: go-github-com-arceliar-ironwood: Enable tests.
    
    * gnu/packages/golang.scm (go-github-com-arceliar-ironwood): Enable most
    of the tests.
    [arguments]: <#:phases>: Add 'remove-examples and use custom 'check
    phase.
    [propagated-inputs]: Add go-github-com-bits-and-blooms-bitset and
    go-github-com-bits-and-blooms-bloom-v3.
    
    Change-Id: I3319e291927e8aa53ce90d00d2cbf6a9df684568
---
 gnu/packages/golang.scm | 26 +++++++++++++++++++-------
 1 file changed, 19 insertions(+), 7 deletions(-)

diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index 82575caa94..11d806c3de 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -8176,14 +8176,26 @@ dependencies and a simple API.")
          "06ay82gqm3k649m7x0r3a3crnqv9x0yxhyqfabrf1b7inki35mfs"))))
     (build-system go-build-system)
     (arguments
-     (list #:import-path "github.com/Arceliar/ironwood"
-           #:tests? #f
-           #:phases
-           #~(modify-phases %standard-phases
-             ;; Source-only package
-             (delete 'build))))
+     (list
+      #:import-path "github.com/Arceliar/ironwood"
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'remove-examples
+            (lambda* (#:key import-path #:allow-other-keys)
+              (delete-file-recursively
+               (string-append "src/" import-path "/cmd/ironwood-example"))))
+          ;; 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-golang-org-x-crypto go-github-com-arceliar-phony))
+     (list go-github-com-arceliar-phony
+           go-github-com-bits-and-blooms-bitset
+           go-github-com-bits-and-blooms-bloom-v3
+           go-golang-org-x-crypto))
     (home-page "https://github.com/Arceliar/ironwood";)
     (synopsis "Experimental network routing library")
     (description



reply via email to

[Prev in Thread] Current Thread [Next in Thread]