"app-name":"${app1_name}",
             "values":
                {
-                  "collectd_prometheus.service.name":"collectd-override-by-set-value"
+                  "collectd_prometheus.service.targetPort":"9104"
                }
          },
          {
             "app-name":"${app2_name}",
             "values":
                {
-                  "service.name":"Prometheus-override-by-set-value"
+                  "prometheus.service.nameOfPort":"WebPort9090"
                }
          }
       ]
 
 collectd_prometheus:
   service:
     type: ClusterIP
-    name: collectd-override-by-file
-    port: 9103
+    port: 9104
     targetPort: 9103
     selector:
       app: collectd
 
   {{- end }}
 {{- end }}
   ports:
-  - name: web
+  - name: {{ .Values.prometheus.service.nameOfPort }}
     {{- if eq .Values.prometheus.service.type "NodePort" }}
     nodePort: {{ .Values.global.nodePortPrefix }}{{ .Values.prometheus.service.nodePort }}
     {{- end }}
     port: 9090
-    targetPort: web
+    targetPort: {{ .Values.prometheus.service.nameOfPort }}
   selector:
     app: prometheus
     prometheus: {{ template "prometheus.fullname" . }}-prometheus
 
 
   resources: {}
   service:
+    nameOfPort: web
     type: ClusterIP
-    name: Prometheus-value-file
     annotations: {}
     labels: {}
     clusterIP: ""
 
 service:
     type: ClusterIP
-    name: Prometheus-override-by-file
+    nameOfPort: webPort
     annotations: {}
     labels: {}
     clusterIP: ""
\ No newline at end of file
 
        k8s.io/client-go => k8s.io/client-go v11.0.1-0.20190409021438-1a26190bd76a+incompatible
        k8s.io/cloud-provider => k8s.io/cloud-provider v0.0.0-20190409023720-1bc0c81fa51d
 )
-
-go 1.13
 
 
        "github.com/onap/multicloud-k8s/src/k8splugin/internal/db"
        "github.com/onap/multicloud-k8s/src/k8splugin/internal/helm"
+
        pkgerrors "github.com/pkg/errors"
 )
 
 
        client moduleLib.InstantiationManager
 }
 
-// func (h instantiationHandler) approveInstantiationHandler(w http.ResponseWriter, r *http.Request) {
-
-//     vars := mux.Vars(r)
-//     p := vars["project-name"]
-//     ca := vars["composite-app-name"]
-//     v := vars["composite-app-version"]
-//     di := vars["deployment-intent-group-name"]
-
-//     instantiateErr := h.client.ApproveInstantiation(p, ca, v, di)
-//     if instantiateErr != nil {
-//             http.Error(w, instantiateErr.Error(), http.StatusInternalServerError)
-//             return
-//     }
-
-//     w.WriteHeader(http.StatusCreated)
-// }
-
 func (h instantiationHandler) instantiateHandler(w http.ResponseWriter, r *http.Request) {
 
        vars := mux.Vars(r)
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: testchart1
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: subcharta
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+# subchartA
+service:
+  name: apache
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+SCAdata:
+  SCAbool: false
+  SCAfloat: 3.1
+  SCAint: 55
+  SCAstring: "jabba"
+  SCAnested1:
+    SCAnested2: true
+
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: subchartb
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+service:
+  name: nginx
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+
+SCBdata:
+  SCBbool: true
+  SCBfloat: 7.77
+  SCBint: 33
+  SCBstring: "boba"
+
+exports:
+  SCBexported1:
+    SCBexported1A:
+      SCBexported1B: 1965
+
+  SCBexported2:
+    SCBexported2A: "blaster"
+
+global:
+  kolla:
+    nova:
+      api:
+        all:
+          port: 8774
+      metadata:
+        all:
+          port: 8775
+
+
+
 
--- /dev/null
+Sample notes for {{ .Chart.Name }}
\ No newline at end of file
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+    namespace: "{{ .Release.Namespace }}"
+    release-name: "{{ .Release.Name }}"
+    release-is-upgrade: "{{ .Release.IsUpgrade }}"
+    release-is-install: "{{ .Release.IsInstall }}"
+    kube-version/major: "{{ .Capabilities.KubeVersion.Major }}"
+    kube-version/minor: "{{ .Capabilities.KubeVersion.Minor }}"
+    kube-version/gitversion: "v{{ .Capabilities.KubeVersion.Major }}.{{ .Capabilities.KubeVersion.Minor }}.0"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+# subchart1
+service:
+  name: nginx
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+
+
+SC1data:
+  SC1bool: true
+  SC1float: 3.14
+  SC1int: 100
+  SC1string: "dollywood"
+  SC1extra1: 11
+
+imported-chartA:
+  SC1extra2: 1.337
+
+overridden-chartA:
+  SCAbool: true
+  SCAfloat: 3.14
+  SCAint: 100
+  SCAstring: "jabathehut"
+  SC1extra3: true
+
+imported-chartA-B:
+  SC1extra5: "tiller"
+
+overridden-chartA-B:
+  SCAbool: true
+  SCAfloat: 3.33
+  SCAint: 555
+  SCAstring: "wormwood"
+  SCAextra1: 23
+
+  SCBbool: true
+  SCBfloat: 0.25
+  SCBint: 98
+  SCBstring: "murkwood"
+  SCBextra1: 13
+
+  SC1extra6: 77
+
+SCBexported1A:
+  SC1extra7: true
+
+exports:
+  SC1exported1:
+    global:
+      SC1exported2:
+        all:
+          SC1exported3: "SC1expstr"
\ No newline at end of file
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: testchart2
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: subcharta
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+# subchartA
+service:
+  name: apache
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+SCAdata:
+  SCAbool: false
+  SCAfloat: 3.1
+  SCAint: 55
+  SCAstring: "jabba"
+  SCAnested1:
+    SCAnested2: true
+
 
--- /dev/null
+apiVersion: v1
+description: A Helm chart for Kubernetes
+name: subchartb
+version: 0.1.0
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+service:
+  name: nginx
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+
+SCBdata:
+  SCBbool: true
+  SCBfloat: 7.77
+  SCBint: 33
+  SCBstring: "boba"
+
+exports:
+  SCBexported1:
+    SCBexported1A:
+      SCBexported1B: 1965
+
+  SCBexported2:
+    SCBexported2A: "blaster"
+
+global:
+  kolla:
+    nova:
+      api:
+        all:
+          port: 8774
+      metadata:
+        all:
+          port: 8775
+
+
+
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: testchart2
+  labels:
+    chart: "testchart2-0.1.0"
+    namespace: "testnamespace"
+    release-name: "testreleasename"
+    release-is-upgrade: "false"
+    release-is-install: "true"
+    kube-version/major: "1"
+    kube-version/minor: "14"
+    kube-version/gitversion: "v1.14.0"
+spec:
+  type: ClusterIP
+  ports:
+  - port: 80
+    targetPort: 80
+    protocol: TCP
+    name: nginx
+  selector:
+    app: testchart2
\ No newline at end of file
 
--- /dev/null
+Sample notes for {{ .Chart.Name }}
\ No newline at end of file
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+    namespace: "{{ .Release.Namespace }}"
+    release-name: "{{ .Release.Name }}"
+    release-is-upgrade: "{{ .Release.IsUpgrade }}"
+    release-is-install: "{{ .Release.IsInstall }}"
+    kube-version/major: "{{ .Capabilities.KubeVersion.Major }}"
+    kube-version/minor: "{{ .Capabilities.KubeVersion.Minor }}"
+    kube-version/gitversion: "v{{ .Capabilities.KubeVersion.Major }}.{{ .Capabilities.KubeVersion.Minor }}.0"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+# subchart1
+service:
+  name: nginx
+  type: ClusterIP
+  externalPort: 80
+  internalPort: 80
+
+
+SC1data:
+  SC1bool: true
+  SC1float: 3.14
+  SC1int: 100
+  SC1string: "dollywood"
+  SC1extra1: 11
+
+imported-chartA:
+  SC1extra2: 1.337
+
+overridden-chartA:
+  SCAbool: true
+  SCAfloat: 3.14
+  SCAint: 100
+  SCAstring: "jabathehut"
+  SC1extra3: true
+
+imported-chartA-B:
+  SC1extra5: "tiller"
+
+overridden-chartA-B:
+  SCAbool: true
+  SCAfloat: 3.33
+  SCAint: 555
+  SCAstring: "wormwood"
+  SCAextra1: 23
+
+  SCBbool: true
+  SCBfloat: 0.25
+  SCBint: 98
+  SCBstring: "murkwood"
+  SCBextra1: 13
+
+  SC1extra6: 77
+
+SCBexported1A:
+  SC1extra7: true
+
+exports:
+  SC1exported1:
+    global:
+      SC1exported2:
+        all:
+          SC1exported3: "SC1expstr"
\ No newline at end of file
 
--- /dev/null
+---
+version: v1
+type:
+  values: "override_values.yaml"
+  configresource:
+    - filepath: subdir/p1.yaml
+      chartpath: testchart1/folderdoesNOTexist/p1.yaml
 
--- /dev/null
+---
+version: v1
+type:
+  values: 
+    - override_values.yaml
+  configresource:
+  - filepath: subdir/p1.yaml
+    chartpath: testchart1/templates/p1.yaml
 
--- /dev/null
+---
+version: v1
+type:
+  values: "override_values.yaml"
+  configresource:
+    - filepath: subdir/filedoesNOTexist.yaml
+      chartpath: testchart1/templates/p1.yaml
 
--- /dev/null
+---
+version: v1
+type:
+  values: "override_values.yaml"
+  configresource:
+    - filepath: subdir/p1.yaml
+      chartpath: testchart1/templates/p1.yaml
 
--- /dev/null
+# Default values for subchart.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+# subchart1
+service:
+  name: nginx
+  type: ClusterIP
+  externalPort: 8080
+  internalPort: 8080
\ No newline at end of file
 
--- /dev/null
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ .Chart.Name }}-override
+  labels:
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+    namespace: "{{ .Release.Namespace }}"
+    release-name: "{{ .Release.Name }}"
+    release-is-upgrade: "{{ .Release.IsUpgrade }}"
+    release-is-install: "{{ .Release.IsInstall }}"
+    kube-version/major: "{{ .Capabilities.KubeVersion.Major }}"
+    kube-version/minor: "{{ .Capabilities.KubeVersion.Minor }}"
+    kube-version/gitversion: "v{{ .Capabilities.KubeVersion.Major }}.{{ .Capabilities.KubeVersion.Minor }}.0"
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    protocol: TCP
+    name: {{ .Values.service.name }}
+  selector:
+    app: {{ .Chart.Name }}
 
        "fmt"
        "github.com/onap/multicloud-k8s/src/orchestrator/utils/helm"
 
-       "github.com/onap/multicloud-k8s/src/orchestrator/utils/types"
        pkgerrors "github.com/pkg/errors"
 
        "encoding/base64"
 
 // GetSortedTemplateForApp returns the sorted templates.
 //It takes in arguments - appName, project, compositeAppName, releaseName, compositeProfileName, array of override values
-func GetSortedTemplateForApp(appName, p, ca, v, rName, cp string, overrideValues []OverrideValues) ([]types.KubernetesResourceTemplate, error) {
+func GetSortedTemplateForApp(appName, p, ca, v, rName, cp string, overrideValues []OverrideValues) ([]helm.KubernetesResourceTemplate, error) {
 
        log.Println("Processing App.. ", appName)
 
-       var sortedTemplates []types.KubernetesResourceTemplate
+       var sortedTemplates []helm.KubernetesResourceTemplate
 
        aC, err := NewAppClient().GetAppContent(appName, p, ca, v)
        if err != nil {
        sortedTemplates, err = helm.NewTemplateClient("", "default", rName,
                ManifestFileName).Resolve(appContent,
                appProfileContent, overrideValuesOfAppStr,
-               rName, appName)
+               appName)
 
        log.Printf("The len of the sortedTemplates :: %d", len(sortedTemplates))
 
 
 
 // Delete all function
 func (c *MockContextDb) DeleteAll(key string) error {
-       for kvKey, _ := range c.Items {
+       for kvKey := range c.Items {
                delete(c.Items, kvKey)
        }
        return c.Err
 func (c *MockContextDb) GetAllKeys(path string) ([]string, error) {
        var keys []string
 
-       for k, _ := range c.Items {
+       for k := range c.Items {
                keys = append(keys, string(k))
        }
        return keys, c.Err
 
 import (
        "bytes"
        utils "github.com/onap/multicloud-k8s/src/orchestrator/utils"
-       "github.com/onap/multicloud-k8s/src/orchestrator/utils/types"
 
        pkgerrors "github.com/pkg/errors"
        "log"
        "k8s.io/helm/pkg/timeconv"
 )
 
+//KubernetesResourceTemplate - Represents the template that is used to create a particular
+//resource in Kubernetes
+type KubernetesResourceTemplate struct {
+       // Tracks the apiVersion and Kind of the resource
+       GVK schema.GroupVersionKind
+       // Path to the file that contains the resource info
+       FilePath string
+}
+
 // Template is the interface for all helm templating commands
 // Any backend implementation will implement this interface and will
 // access the functionality via this.
 
 // GenerateKubernetesArtifacts a mapping of type to fully evaluated helm template
 func (h *TemplateClient) GenerateKubernetesArtifacts(inputPath string, valueFiles []string,
-       values []string) ([]types.KubernetesResourceTemplate, error) {
+       values []string) ([]KubernetesResourceTemplate, error) {
 
        var outputDir, chartPath, namespace, releaseName string
-       var retData []types.KubernetesResourceTemplate
+       var retData []KubernetesResourceTemplate
 
        releaseName = h.releaseName
        namespace = h.kubeNameSpace
                        return retData, err
                }
 
-               kres := types.KubernetesResourceTemplate{
+               kres := KubernetesResourceTemplate{
                        GVK:      gvk,
                        FilePath: mfilePath,
                }
 
 // Resolver is an interface exposes the helm related functionalities
 type Resolver interface {
-       Resolve(appContent, appProfileContent []byte, overrideValuesOfAppStr []string, rName string) ([]types.KubernetesResourceTemplate, error)
+       Resolve(appContent, appProfileContent []byte, overrideValuesOfAppStr []string, appName string) ([]KubernetesResourceTemplate, error)
 }
 
 // Resolve function
-func (h *TemplateClient) Resolve(appContent []byte, appProfileContent []byte, overrideValuesOfAppStr []string, rName, appName string) ([]types.KubernetesResourceTemplate, error) {
+func (h *TemplateClient) Resolve(appContent []byte, appProfileContent []byte, overrideValuesOfAppStr []string, appName string) ([]KubernetesResourceTemplate, error) {
+
+       var sortedTemplates []KubernetesResourceTemplate
 
-       var sortedTemplates []types.KubernetesResourceTemplate
+       //chartBasePath is the tmp path where the appContent(rawHelmCharts) is extracted.
+       chartBasePath, err := utils.ExtractTarBall(bytes.NewBuffer(appContent))
+       if err != nil {
+               return sortedTemplates, pkgerrors.Wrap(err, "Extracting appContent")
+       }
+       log.Printf("The chartBasePath :: %s", chartBasePath)
 
        //prPath is the tmp path where the appProfileContent is extracted.
        prPath, err := utils.ExtractTarBall(bytes.NewBuffer(appProfileContent))
        }
        log.Printf("The profile path:: %s", prPath)
 
-       prYamlClient, err := utils.ProcessProfileYaml(prPath, h.manifestName)
+       prYamlClient, err := ProcessProfileYaml(prPath, h.manifestName)
        if err != nil {
                return sortedTemplates, pkgerrors.Wrap(err, "Processing Profile Manifest")
        }
        log.Println("Got the profileYamlClient..")
 
-       //chartBasePath is the tmp path where the appContent(rawHelmCharts) is extracted.
-       chartBasePath, err := utils.ExtractTarBall(bytes.NewBuffer(appContent))
-       log.Printf("The chartBasePath :: %s", chartBasePath)
-
        err = prYamlClient.CopyConfigurationOverrides(chartBasePath)
        if err != nil {
                return sortedTemplates, pkgerrors.Wrap(err, "Copying configresources to chart")
 
--- /dev/null
+/*
+ * Copyright 2020 Intel Corporation, Inc
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package helm
+
+import (
+       "crypto/sha256"
+       "fmt"
+
+       "io/ioutil"
+       "path/filepath"
+       "strings"
+       "testing"
+)
+
+func TestProcessValues(t *testing.T) {
+
+       chartDir := "../../mock_files/mock_charts/testchart2"
+       profileDir := "../../mock_files/mock_profiles/profile1"
+
+       testCases := []struct {
+               label         string
+               valueFiles    []string
+               values        []string
+               expectedHash  string
+               expectedError string
+       }{
+               {
+                       label: "Process Values with Value Files Override",
+                       valueFiles: []string{
+                               filepath.Join(chartDir, "values.yaml"),
+                               filepath.Join(profileDir, "override_values.yaml"),
+                       },
+                       //Hash of a combined values.yaml file that is expected
+                       expectedHash:  "c18a70f426933de3c051c996dc34fd537d0131b2d13a2112a2ecff674db6c2f9",
+                       expectedError: "",
+               },
+               {
+                       label: "Process Values with Values Pair Override",
+                       valueFiles: []string{
+                               filepath.Join(chartDir, "values.yaml"),
+                       },
+                       //Use the same convention as specified in helm template --set
+                       values: []string{
+                               "service.externalPort=82",
+                       },
+                       //Hash of a combined values.yaml file that is expected
+                       expectedHash:  "028a3521fc9f8777ea7e67a6de0c51f2c875b88ca91734999657f0ca924ddb7a",
+                       expectedError: "",
+               },
+               {
+                       label: "Process Values with Both Overrides",
+                       valueFiles: []string{
+                               filepath.Join(chartDir, "values.yaml"),
+                               filepath.Join(profileDir, "override_values.yaml"),
+                       },
+                       //Use the same convention as specified in helm template --set
+                       //Key takes precedence over the value from override_values.yaml
+                       values: []string{
+                               "service.externalPort=82",
+                       },
+                       //Hash of a combined values.yaml file that is expected
+                       expectedHash:  "516fab4ab7b76ba2ff35a97c2a79b74302543f532857b945f2fe25e717e755be",
+                       expectedError: "",
+               },
+               {
+                       label: "Process complex Pair Override",
+                       values: []string{
+                               "name={a,b,c}",
+                               "servers[0].port=80",
+                       },
+                       expectedError: "",
+                       expectedHash:  "50d9401b003f65c1ccfd1c5155106fff88c8201ab8b7d66bd6ffa4fe2883bead",
+               },
+       }
+
+       h := sha256.New()
+
+       for _, testCase := range testCases {
+               t.Run(testCase.label, func(t *testing.T) {
+                       tc := NewTemplateClient("1.12.3", "testnamespace", "testreleasename", "manifest.yaml")
+                       out, err := tc.processValues(testCase.valueFiles, testCase.values)
+                       if err != nil {
+                               if testCase.expectedError == "" {
+                                       t.Fatalf("Got an error %s", err)
+                               }
+                               if strings.Contains(err.Error(), testCase.expectedError) == false {
+                                       t.Fatalf("Got unexpected error message %s", err)
+                               }
+                       } else {
+                               //Compute the hash of returned data and compare
+                               h.Write(out)
+                               gotHash := fmt.Sprintf("%x", h.Sum(nil))
+                               h.Reset()
+                               if gotHash != testCase.expectedHash {
+                                       t.Fatalf("Got unexpected hash '%s' of values.yaml:\n%s", gotHash, out)
+                               }
+                       }
+               })
+       }
+}
+
+func TestGenerateKubernetesArtifacts(t *testing.T) {
+
+       chartDir := "../../mock_files/mock_charts/testchart2"
+       profileDir := "../../mock_files/mock_profiles/profile1"
+
+       testCases := []struct {
+               label           string
+               chartPath       string
+               valueFiles      []string
+               values          []string
+               expectedHashMap map[string]string
+               expectedError   string
+       }{
+               {
+                       label:      "Generate artifacts without any overrides",
+                       chartPath:  chartDir,
+                       valueFiles: []string{},
+                       values:     []string{},
+                       //sha256 hash of the evaluated templates in each chart
+                       expectedHashMap: map[string]string{
+                               "testchart2/templates/service.yaml": "fdd6a2b6795486f0dd1d8c44379afb5ffe4072c09f9cf6594738e8ded4dd872d",
+                               "subcharta/templates/service.yaml":  "570389588fffdb7193ab265888d781f3d751f3a40362533344f9aa7bb93a8bb0",
+                               "subchartb/templates/service.yaml":  "5654e03d922e8ec49649b4bbda9dfc9e643b3b7c9c18b602cc7e26fd36a39c2a",
+                       },
+                       expectedError: "",
+               },
+               {
+                       label:     "Generate artifacts with overrides",
+                       chartPath: chartDir,
+                       valueFiles: []string{
+                               filepath.Join(profileDir, "override_values.yaml"),
+                       },
+                       values: []string{
+                               "service.externalPort=82",
+                       },
+                       //sha256 hash of the evaluated templates in each chart
+                       expectedHashMap: map[string]string{
+                               "testchart2/templates/service.yaml": "2bb96e791ecb6a3404bc5de3f6c4182aed881630269e2aa6766df38b0f852724",
+                               "subcharta/templates/service.yaml":  "570389588fffdb7193ab265888d781f3d751f3a40362533344f9aa7bb93a8bb0",
+                               "subchartb/templates/service.yaml":  "5654e03d922e8ec49649b4bbda9dfc9e643b3b7c9c18b602cc7e26fd36a39c2a",
+                       },
+                       expectedError: "",
+               },
+       }
+
+       h := sha256.New()
+
+       for _, testCase := range testCases {
+               t.Run(testCase.label, func(t *testing.T) {
+                       tc := NewTemplateClient("1.12.3", "testnamespace", "testreleasename", "manifest.yaml")
+                       out, err := tc.GenerateKubernetesArtifacts(testCase.chartPath, testCase.valueFiles,
+                               testCase.values)
+                       if err != nil {
+                               if testCase.expectedError == "" {
+                                       t.Fatalf("Got an error %s", err)
+                               }
+                               if strings.Contains(err.Error(), testCase.expectedError) == false {
+                                       t.Fatalf("Got unexpected error message %s", err)
+                               }
+                       } else {
+                               //Compute the hash of returned data and compare
+                               for _, v := range out {
+                                       f := v.FilePath
+                                       data, err := ioutil.ReadFile(f)
+                                       if err != nil {
+                                               t.Errorf("Unable to read file %s", v)
+                                       }
+                                       h.Write(data)
+                                       gotHash := fmt.Sprintf("%x", h.Sum(nil))
+                                       h.Reset()
+
+                                       //Find the right hash from expectedHashMap
+                                       expectedHash := ""
+                                       for k1, v1 := range testCase.expectedHashMap {
+                                               if strings.Contains(f, k1) == true {
+                                                       expectedHash = v1
+                                                       break
+                                               }
+                                       }
+                                       if gotHash != expectedHash {
+                                               t.Fatalf("Got unexpected hash for %s", f)
+                                       }
+                               }
+                       }
+               })
+       }
+
+}
 
  * limitations under the License.
  */
 
-package utils
+package helm
 
 import (
        "io/ioutil"
 
+++ /dev/null
-/*
- * Copyright 2020 Intel Corporation, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package types
-
-import (
-       "k8s.io/apimachinery/pkg/runtime/schema"
-)
-
-// KubernetesResourceTemplate - Represents the template that is used to create a particular
-// resource in Kubernetes
-type KubernetesResourceTemplate struct {
-       // Tracks the apiVersion and Kind of the resource
-       GVK schema.GroupVersionKind
-       // Path to the file that contains the resource info
-       FilePath string
-}
-
-// KubernetesResource is the resource that is created in Kubernetes
-// It is the type that will be used for tracking a resource.
-// Any future information such as status, time can be added here
-// for tracking.
-type KubernetesResource struct {
-       // Tracks the apiVersion and Kind of the resource
-       GVK schema.GroupVersionKind
-       // Name of resource in Kubernetes
-       Name string
-}