test: fix DecryptSecret output

This commit is contained in:
Andrey Tuzhilin 2021-03-16 12:07:56 +03:00 committed by Yusuke Kuoka
parent 4a9d753441
commit db9d31ac06
1 changed files with 3 additions and 3 deletions

View File

@ -3,7 +3,6 @@ package helmexec
import ( import (
"bytes" "bytes"
"fmt" "fmt"
"github.com/google/go-cmp/cmp"
"io" "io"
"os" "os"
"path" "path"
@ -11,6 +10,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/google/go-cmp/cmp"
"github.com/Masterminds/semver/v3" "github.com/Masterminds/semver/v3"
"go.uber.org/zap" "go.uber.org/zap"
) )
@ -282,8 +283,7 @@ Decrypting secret %s/secretName
exec: helm --kube-context dev secrets dec %s/secretName exec: helm --kube-context dev secrets dec %s/secretName
Preparing to decrypt secret %s/secretName Preparing to decrypt secret %s/secretName
Found secret in cache %s/secretName Found secret in cache %s/secretName
Decrypted %s/secretName into path/to/temp/file `, cwd, cwd, cwd, cwd, cwd)
`, cwd, cwd, cwd, cwd, cwd, cwd)
if d := cmp.Diff(expected, buffer.String()); d != "" { if d := cmp.Diff(expected, buffer.String()); d != "" {
t.Errorf("helmexec.DecryptSecret(): want (-), got (+):\n%s", d) t.Errorf("helmexec.DecryptSecret(): want (-), got (+):\n%s", d)
} }