add unit test for export format

- add coverage for cannonical export format
   - add new subchart3 for testing purposes

solved: #7045
Signed-off-by: ferantivero <v-fean@microsoft.com>
pull/7047/head
ferantivero 6 years ago
parent 139bfa66a5
commit f9428817f7

@ -295,6 +295,9 @@ func TestProcessRequirementsImportValues(t *testing.T) {
e["SCBexported2A"] = "blaster"
e["global.SC1exported2.all.SC1exported3"] = "SC1expstr"
e["SCCdata.SCCstring"] = "mugwort"
e["SCCdata.SCCint"] = "42"
verifyRequirementsImportValues(t, c, v, e)
}
func verifyRequirementsImportValues(t *testing.T, c *chart.Chart, v *chart.Config, e map[string]string) {

@ -0,0 +1,22 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/

@ -0,0 +1,5 @@
apiVersion: v1
appVersion: "1.0"
description: A Helm chart for Kubernetes
name: subchart3
version: 0.1.0

@ -0,0 +1,4 @@
exports:
data:
SCCdata:
SCCstring: "mugwort"

@ -35,3 +35,12 @@ dependencies:
repository: http://localhost:10191
version: 0.1.0
condition: subchart2alias.enabled
- name: subchart3
repository: http://localhost:10191
version: 0.1.0
condition: subchart3.enabled
import-values:
- data

@ -35,9 +35,16 @@ overridden-chartA-B:
SCBstring: "jango"
SPextra6: 111
SCCdata:
SCCstring: "jaberwocky"
SCCint: 42
tags:
front-end: true
back-end: false
subchart3:
enabled: false
subchart2alias:
enabled: false
Loading…
Cancel
Save