Skip to content
Snippets Groups Projects
Commit f376b5af authored by Florent Aide's avatar Florent Aide
Browse files

prove beaver build bug

parent 9fa4c3ac
No related branches found
No related tags found
No related merge requests found
......@@ -57,7 +57,7 @@
require.Equal(t, 4, len(yttPatches))
})
t.Run("helmCharts", func(t *testing.T) {
t.Run("build", func(t *testing.T) {
buildDir := filepath.Join(fixtures, "build", "ns1")
defer func() {
require.NoError(t, runner.CleanDir(buildDir))
......@@ -69,6 +69,10 @@
deploy, err := parseFile(deployment)
require.NoError(t, err)
odooConf := filepath.Join(buildDir, "Secret.v1.odoo_conf.yaml")
_, err = parseFile(odooConf)
require.NoError(t, err, "we produced an invalid yaml resource")
envVars, err := getEnvVars(deploy)
require.NoError(t, err)
......@@ -146,7 +150,7 @@
func TestYamlSplit(t *testing.T) {
namespace := "ns1"
compiled := "output.yaml"
compiled := "test_split_input.yaml"
buildDir := filepath.Join(fixtures, "build", namespace)
compiledFiles, err := runner.YamlSplit(buildDir, filepath.Join(fixtures, compiled))
require.NoError(t, err)
......
......@@ -87,8 +87,15 @@
input := `
---
foo: <[foo]>
bar: |
[section1]
value1 = 1
# ----------
# some comment
# ----------
value2 = 2
replicas: 1
`
expected := `
---
foo: 33
......@@ -90,8 +97,15 @@
replicas: 1
`
expected := `
---
foo: 33
bar: |-
[section1]
value1 = 1
# ----------
# some comment
# ----------
value2 = 2
replicas: 1
`
......
......@@ -10,6 +10,9 @@
odoo:
type: ytt
path: ../vendor/ytt/odoo
extra:
type: ytt
path: extra.tmpl.yaml
create:
- type: configmap
name: xbus-pipelines
......
---
apiVersion: v1
kind: Secret
metadata:
name: odoo_conf
type: Opaque
stringData:
odoo.conf: |
[option]
foo = 1
bar = 2
# -----------------------------------------------
# Below options are less crucial
# -----------------------------------------------
# yiolo
toot = t00t
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment