Allow tests to run on systems that use busybox (such as Alpine)

This commit is contained in:
Andy Hawkins 2021-03-13 16:02:44 +00:00
parent d523af1b6c
commit 181672afcc

3
webhook_test.go Normal file → Executable file
View file

@ -33,7 +33,8 @@ func TestStaticParams(t *testing.T) {
spHeaders["Accept"] = "*/*"
// case 2: binary with spaces in its name
err := os.Symlink("/bin/echo", "/tmp/with space")
d1 := []byte("#!/bin/sh\n/bin/echo\n")
err := ioutil.WriteFile("/tmp/with space", d1, 0755)
if err != nil {
t.Fatalf("%v", err)
}