From d555af68fe297b597bb4d6a0143d4377976078bb Mon Sep 17 00:00:00 2001 From: Jamie Curnow Date: Tue, 25 Jul 2023 12:15:58 +1000 Subject: [PATCH] Fix acme.sh ci test --- backend/internal/acme/acmesh_test.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/backend/internal/acme/acmesh_test.go b/backend/internal/acme/acmesh_test.go index 36e6509..57a0ba1 100644 --- a/backend/internal/acme/acmesh_test.go +++ b/backend/internal/acme/acmesh_test.go @@ -197,8 +197,12 @@ func TestBuildCertRequestArgs(t *testing.T) { func TestGetAcmeShFilePath(t *testing.T) { t.Run("basic test", func(t *testing.T) { path, err := getAcmeShFilePath() - assert.Equal(t, "/bin/acme.sh", path) - assert.Equal(t, nil, err) + if err != nil { + assert.Equal(t, "Cannot find acme.sh execuatable script in PATH: exec: \"acme.sh\": executable file not found in $PATH", err.Error()) + assert.Equal(t, "", path) + } else { + assert.Equal(t, "/bin/acme.sh", path) + } }) }