summaryrefslogtreecommitdiffstats
path: root/src/k8splugin/internal/app
diff options
context:
space:
mode:
authorVictor Morales <victor.morales@intel.com>2019-04-02 17:20:12 +0000
committerGerrit Code Review <gerrit@onap.org>2019-04-02 17:20:12 +0000
commit408200f3c402fa31fc465b5cd8b2ea4340048468 (patch)
tree8de5c58ed150e3f2339ad29b78c47dc847f624fe /src/k8splugin/internal/app
parenta1e2fb3ff225509885f82311096d0353e1117877 (diff)
parentf3875e13c7a6675aa980c29580daae42a32eb97f (diff)
Merge "Make profile key explicit"
Diffstat (limited to 'src/k8splugin/internal/app')
-rw-r--r--src/k8splugin/internal/app/vnfhelper.go4
-rw-r--r--src/k8splugin/internal/app/vnfhelper_test.go4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/k8splugin/internal/app/vnfhelper.go b/src/k8splugin/internal/app/vnfhelper.go
index 0a867090..c5783d69 100644
--- a/src/k8splugin/internal/app/vnfhelper.go
+++ b/src/k8splugin/internal/app/vnfhelper.go
@@ -47,7 +47,7 @@ func ensuresNamespace(namespace string, kubeclient kubernetes.Interface) error {
return pkgerrors.Wrap(err, "Error fetching get namespace function")
}
- ns, _ := symGetNamespaceFunc.(func(string, string, kubernetes.Interface) (string, error))(
+ ns, _ := symGetNamespaceFunc.(func(string, string, kubernetes.Interface) (string, error))(
namespace, namespace, kubeclient)
if ns == "" {
@@ -80,7 +80,7 @@ var CreateVNF = func(csarID string, cloudRegionID string, profile rb.Profile, ku
externalVNFID := generateExternalVNFID()
internalVNFID := cloudRegionID + "-" + profile.Namespace + "-" + externalVNFID
- metaMap, err := rb.NewProfileClient().Resolve(profile.RBName, profile.RBVersion, profile.Name, overrideValues)
+ metaMap, err := rb.NewProfileClient().Resolve(profile.RBName, profile.RBVersion, profile.ProfileName, overrideValues)
if err != nil {
return "", nil, pkgerrors.Wrap(err, "Error resolving helm charts")
}
diff --git a/src/k8splugin/internal/app/vnfhelper_test.go b/src/k8splugin/internal/app/vnfhelper_test.go
index 6722bfa8..7587e5d6 100644
--- a/src/k8splugin/internal/app/vnfhelper_test.go
+++ b/src/k8splugin/internal/app/vnfhelper_test.go
@@ -84,7 +84,7 @@ func TestCreateVNF(t *testing.T) {
db.DBconn = &db.MockDB{
Items: map[string]map[string][]byte{
rb.ProfileKey{RBName: "test-rbdef", RBVersion: "v1",
- Name: "profile1"}.String(): {
+ ProfileName: "profile1"}.String(): {
"metadata": []byte(
"{\"profile-name\":\"profile1\"," +
"\"release-name\":\"testprofilereleasename\"," +
@@ -194,7 +194,7 @@ func TestCreateVNF(t *testing.T) {
rb.Profile{
RBName: "test-rbdef",
RBVersion: "v1",
- Name: "profile1",
+ ProfileName: "profile1",
ReleaseName: "testprofilereleasename",
Namespace: "testnamespace",
KubernetesVersion: "1.12.3",