summaryrefslogtreecommitdiff
path: root/gnu/packages/patches/containerd-test-with-go1.13.patch
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2020-02-24 19:37:03 +0100
committerMarius Bakke <mbakke@fastmail.com>2020-02-24 19:37:03 +0100
commit3941af527df6f27c88258c5d3b78720a07fe60ef (patch)
tree4747f74f32faef8a4f20bf7adf797ce57a8324fc /gnu/packages/patches/containerd-test-with-go1.13.patch
parentd85f8e46dbc5a978fe7359c89cbb3167fb9c2029 (diff)
parent7daae3c9d09a4d27586824a1d1af99e7af454d26 (diff)
Merge branch 'master' into staging
Diffstat (limited to 'gnu/packages/patches/containerd-test-with-go1.13.patch')
-rw-r--r--gnu/packages/patches/containerd-test-with-go1.13.patch21
1 files changed, 21 insertions, 0 deletions
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 0000000000..964adee9e6
--- /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())
+ }