fix: fixes a regexp issue for release summary (#666)

There was an issue a the regexp reding the version from helm output.

Fixes #665
This commit is contained in:
sgandon
2019-06-10 09:18:41 +09:00
committed by KUOKA Yusuke
parent 34c793d87e
commit 56c27c2bd9
2 changed files with 21 additions and 8 deletions
+13 -2
View File
@@ -1,14 +1,15 @@
package state
import (
"github.com/roboll/helmfile/pkg/helmexec"
"github.com/roboll/helmfile/pkg/testhelper"
"io/ioutil"
"os"
"path/filepath"
"reflect"
"testing"
"github.com/roboll/helmfile/pkg/helmexec"
"github.com/roboll/helmfile/pkg/testhelper"
"errors"
"strings"
@@ -1232,6 +1233,16 @@ func TestGetDeployedVersion(t *testing.T) {
foo 1 Wed Apr 17 17:39:04 2019 DEPLOYED foo-bar-1.0.0-alpha+001 0.1.0 default`,
installedVersion: "1.0.0-alpha+001",
},
{
name: "chart version with dash and release with dash",
release: ReleaseSpec{
Name: "foo-bar",
Chart: "registry/foo-bar",
},
listResult: `NAME REVISION UPDATED STATUS CHART APP VERSION NAMESPACE
foo-bar-release 1 Wed Apr 17 17:39:04 2019 DEPLOYED foo-bar-1.0.0-alpha+001 0.1.0 default`,
installedVersion: "1.0.0-alpha+001",
},
}
for i := range tests {
tt := tests[i]