summary refs log tree commit diff
path: root/gnu/packages/patches/docker-fix-tests.patch
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2019-02-06 13:03:26 +0100
committerRicardo Wurmus <rekado@elephly.net>2019-02-06 13:03:26 +0100
commitba88eea2b3a8a33ecd7fc0ec64e3917c6c2fe21d (patch)
tree75c68e44d3d76440f416552711b1a47ec83e411e /gnu/packages/patches/docker-fix-tests.patch
parentf380f9d55e6757c242acf6c71c4a3ccfcdb066b2 (diff)
parent4aeb7f34c948f32363f2ae29c6942c6328df758c (diff)
downloadguix-ba88eea2b3a8a33ecd7fc0ec64e3917c6c2fe21d.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'gnu/packages/patches/docker-fix-tests.patch')
-rw-r--r--gnu/packages/patches/docker-fix-tests.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/gnu/packages/patches/docker-fix-tests.patch b/gnu/packages/patches/docker-fix-tests.patch
new file mode 100644
index 0000000000..3e3e318e25
--- /dev/null
+++ b/gnu/packages/patches/docker-fix-tests.patch
@@ -0,0 +1,28 @@
+Author: Danny Milosavljevic <dannym@scratchpost.org>
+The socket name ended up too long inside the container.
+Use a shorter one.
+--- a/pkg/authorization/authz_unix_test.go	2019-01-10 01:55:02.997985947 +0100
++++ b/pkg/authorization/authz_unix_test.go	2019-01-10 02:03:21.177439757 +0100
+@@ -24,7 +24,7 @@
+ )
+ 
+ const (
+-	pluginAddress = "authz-test-plugin.sock"
++	pluginAddress = "/tmp/authz-test-plugin.sock"
+ )
+ 
+ func TestAuthZRequestPluginError(t *testing.T) {
+@@ -263,12 +263,7 @@
+ 
+ // createTestPlugin creates a new sample authorization plugin
+ func createTestPlugin(t *testing.T) *authorizationPlugin {
+-	pwd, err := os.Getwd()
+-	if err != nil {
+-		t.Fatal(err)
+-	}
+-
+-	client, err := plugins.NewClient("unix:///"+path.Join(pwd, pluginAddress), &tlsconfig.Options{InsecureSkipVerify: true})
++	client, err := plugins.NewClient("unix:///"+path.Join("/", pluginAddress), &tlsconfig.Options{InsecureSkipVerify: true})
+ 	if err != nil {
+ 		t.Fatalf("Failed to create client %v", err)
+ 	}