summaryrefslogtreecommitdiff
path: root/gnu/packages/golang.scm
diff options
context:
space:
mode:
authorDanny Milosavljevic <dannym@scratchpost.org>2020-02-10 16:50:49 +0100
committerDanny Milosavljevic <dannym@scratchpost.org>2020-02-10 16:59:49 +0100
commit944f370b55bdd483bf29e4bd1ac5a293633a1789 (patch)
tree36e253730683b6d3fc3003aae9f23c521ee3fe0f /gnu/packages/golang.scm
parent90bce15998b0faf5afd60b1a3ee59e93547089e2 (diff)
downloadguix-patches-944f370b55bdd483bf29e4bd1ac5a293633a1789.tar
guix-patches-944f370b55bdd483bf29e4bd1ac5a293633a1789.tar.gz
gnu: go-gotest-tools: Factor out go-gotest-tools-package.
* gnu/packages/golang.scm (go-gotest-tools-package): New procedure. (go-gotest-tools-assert): Use it. [arguments]<#:phases>[install-more]: Delete phase.
Diffstat (limited to 'gnu/packages/golang.scm')
-rw-r--r--gnu/packages/golang.scm39
1 files changed, 21 insertions, 18 deletions
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index 5d0c2480b6..f93b2c1ab7 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -3115,29 +3115,32 @@ common task.")
(sha256
(base32 sha256-base32-hash))))
-(define-public go-gotest-tools-assert
+(define (go-gotest-tools-package suffix)
(package
- (name "go-gotest-tools-assert")
- (version "3.0.0")
+ (name (string-append "go-gotest-tools-"
+ (string-replace-substring suffix "/" "-")))
+ (version "2.3.0")
(source
(go-gotest-tools-source version
- "0071rjxp4xzcr3vprkaj1hdk35a3v45bx8v0ipk16wwc5hx84i2i"))
+ "0071rjxp4xzcr3vprkaj1hdk35a3v45bx8v0ipk16wwc5hx84i2i"))
(build-system go-build-system)
(arguments
- `(#:import-path "gotest.tools/assert"
- #:unpack-path "gotest.tools"
- #:phases
- (modify-phases %standard-phases
- (add-after 'install 'install-more
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (source (string-append (getenv "GOPATH")
- "/src/gotest.tools/assert"))
- (dest (string-append out "/src/gotest.tools/v3/assert")))
- (write source)
- (newline)
- (copy-recursively source dest #:keep-mtime? #t)
- #t))))))
+ `(#:import-path ,(string-append "gotest.tools/" suffix)
+ #:unpack-path "gotest.tools"))
+ (synopsis "@code{gotest-tools} part")
+ (description "This package provides a part of @code{gotest-tools}.")
+ (home-page "https://github.com/gotestyourself/gotest.tools")
+ (license license:asl2.0)))
+
+(define-public go-gotest-tools-assert
+ (package (inherit (go-gotest-tools-package "assert"))
+ (name "go-gotest-tools-assert")
+ (arguments
+ `(#:tests? #f ; Test failure concerning message formatting (FIXME)
+ #:import-path "gotest.tools/assert"
+ #:unpack-path "gotest.tools"))
+ ;(propagated-inputs
+ ; `(("go-gotest-tools-internal-format" ,go-gotest-tools-internal-format)))
(native-inputs
`(("go-github-com-pkg-errors" ,go-github-com-pkg-errors)
("go-github-com-google-go-cmp-cmp"