guix-commits
[Top][All Lists]
Advanced

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

branch master updated: gnu: containerd: Fix test failure with Go 1.13.


From: guix-commits
Subject: branch master updated: gnu: containerd: Fix test failure with Go 1.13.
Date: Sat, 15 Feb 2020 08:32:10 -0500

This is an automated email from the git hooks/post-receive script.

dannym pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new 13c8e74  gnu: containerd: Fix test failure with Go 1.13.
13c8e74 is described below

commit 13c8e747e86e39c0a8c6ec7da8c812d9bbcb682b
Author: Jack Hill <address@hidden>
AuthorDate: Wed Feb 12 15:33:43 2020 -0500

    gnu: containerd: Fix test failure with Go 1.13.
    
    * gnu/packages/docker.scm (containerd)[source]: Add patch.
    * gnu/packages/patches/containerd-test-with-go1.13.patch: New file.
    * gnu/local.mk (dist_patch_DATA): Add patch.
---
 gnu/local.mk                                        |  1 +
 gnu/packages/docker.scm                             |  4 +++-
 .../patches/containerd-test-with-go1.13.patch       | 21 +++++++++++++++++++++
 3 files changed, 25 insertions(+), 1 deletion(-)

diff --git a/gnu/local.mk b/gnu/local.mk
index 9a316f6..1f7cad9 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -794,6 +794,7 @@ dist_patch_DATA =                                           
\
   %D%/packages/patches/coda-use-system-libs.patch              \
   %D%/packages/patches/combinatorial-blas-awpm.patch           \
   %D%/packages/patches/combinatorial-blas-io-fix.patch         \
+  %D%/packages/patches/containerd-test-with-go1.13.patch               \
   %D%/packages/patches/cpufrequtils-fix-aclocal.patch          \
   %D%/packages/patches/crawl-upgrade-saves.patch               \
   %D%/packages/patches/crda-optional-gcrypt.patch              \
diff --git a/gnu/packages/docker.scm b/gnu/packages/docker.scm
index 1f832a2..cc353fd 100644
--- a/gnu/packages/docker.scm
+++ b/gnu/packages/docker.scm
@@ -183,7 +183,9 @@ Python without keeping their credentials in a Docker 
configuration file.")
             (commit (string-append "v" version))))
       (file-name (git-file-name name version))
       (sha256
-       (base32 "0npbzixf3c0jvzm159vygvkydrr8h36c9sq50yv0mdinrys2bvg0"))))
+       (base32 "0npbzixf3c0jvzm159vygvkydrr8h36c9sq50yv0mdinrys2bvg0"))
+      (patches
+        (search-patches "containerd-test-with-go1.13.patch"))))
     (build-system go-build-system)
     (arguments
      `(#:import-path "github.com/containerd/containerd"
diff --git a/gnu/packages/patches/containerd-test-with-go1.13.patch 
b/gnu/packages/patches/containerd-test-with-go1.13.patch
new file mode 100644
index 0000000..964adee
--- /dev/null
+++ b/gnu/packages/patches/containerd-test-with-go1.13.patch
@@ -0,0 +1,21 @@
+Compatibility fix for go 1.13, flag.Parse() shouldn't be called during
+package initialization.
+https://golang.org/doc/go1.13#testing
+--- a/client_test.go   2020-02-12 14:50:28.991245371 -0500
++++ b/client_test.go   2020-02-12 15:12:37.383523980 -0500
+@@ -49,7 +49,6 @@
+       flag.StringVar(&address, "address", defaultAddress, "The address to the 
containerd socket for use in the tests")
+       flag.BoolVar(&noDaemon, "no-daemon", false, "Do not start a dedicated 
daemon for the tests")
+       flag.BoolVar(&noCriu, "no-criu", false, "Do not run the checkpoint 
tests")
+-      flag.Parse()
+ }
+ 
+ func testContext() (context.Context, context.CancelFunc) {
+@@ -59,6 +58,7 @@
+ }
+ 
+ func TestMain(m *testing.M) {
++      flag.Parse()
+       if testing.Short() {
+               os.Exit(m.Run())
+       }



reply via email to

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